declare user_data method public
@@ -372,6 +372,13 @@ impl UserDataLoadable {
user_data_effects
}
}
+ pub fn user_data(&mut self) -> &mut UserData {
+ match self {
+ UserDataLoadable::Loading { content, .. } | UserDataLoadable::Ready { content } => {
+ content
+ }
+ }
+ }
pub fn auth(&self) -> &Option<Auth> {
match &self {
UserDataLoadable::Loading { content, .. } | UserDataLoadable::Ready { content } => {
@@ -393,11 +400,4 @@ impl UserDataLoadable {
}
}
}
- fn user_data(&mut self) -> &mut UserData {
- match self {
- UserDataLoadable::Loading { content, .. } | UserDataLoadable::Ready { content } => {
- content
- }
- }
- }
}
