pub async fn refresh(&self) -> CalDavResult<()> {
        let borrow = self.data.borrow();
        let data = match &*borrow {
            EventPointerData::FetchedEvent(event) => EventPointerData::CreatedEventResponse {
                uid: event
                    .properties
                    .iter()
                    .find(|p| p.name == "UID")
                    .map(Ok)
                    .unwrap_or(Err(CalDavError::OtherError))?
                    .value
                    .clone()
                    .map(Ok)
                    .unwrap_or(Err(CalDavError::OtherError))?,
            },
            EventPointerData::CreatedEventResponse { uid } => {
                EventPointerData::CreatedEventResponse { uid: uid.clone() }
            }
        };
        std::mem::drop(borrow);
        let mut d = self.data.borrow_mut();
        *d = data;
        Ok(())
    }
/// Refreshes the event (by sending a request to the server.)
Refreshes the event (by sending a request to the server.)
Refreshes the event ( by sending a request to the server . )
pub async fn refresh(&self) -> CalDavResult<()> {
        let borrow = self.data.borrow();
        let data = match &*borrow {
            EventPointerData::FetchedEvent(event) => EventPointerData::CreatedEventResponse {
                uid: event
                    .properties
                    .iter()
                    .find(|p| p.name == "UID")
                    .map(Ok)
                    .unwrap_or(Err(CalDavError::OtherError))?
                    .value
                    .clone()
                    .map(Ok)
                    .unwrap_or(Err(CalDavError::OtherError))?,
            },
            EventPointerData::CreatedEventResponse { uid } => {
                EventPointerData::CreatedEventResponse { uid: uid.clone() }
            }
        };
        std::mem::drop(borrow);
        let mut d = self.data.borrow_mut();
        *d = data;
        Ok(())
    }
pub async fn refresh ( & self ) -> CalDavResult < ( ) > { let borrow = self . data . borrow ( ) ; let data = match & * borrow { EventPointerData :: FetchedEvent ( event ) => EventPointerData :: CreatedEventResponse { uid : event . properties . iter ( ) . find ( | p | p . name == " " ) . map ( Ok ) . unwrap_or ( Err ( CalDavError :: OtherError ) ) ? . value . clone ( ) . map ( Ok ) . unwrap_or ( Err ( CalDavError :: OtherError ) ) ? , } , EventPointerData :: CreatedEventResponse { uid } => { EventPointerData :: CreatedEventResponse { uid : uid . clone ( ) } } } ; std :: mem :: drop ( borrow ) ; let mut d = self . data . borrow_mut ( ) ; * d = data ; Ok ( ( ) ) }
Refreshes the event (by sending a request to the server.)
Refreshes the event ( by sending a request to the server . )
&self