osu: make commands aware of user's preferred mode (#54)

* Add preferred_mode to sql database

* Update username and preferred mode

* Make commands aware of preferred mode

* Fetch user extras to display information

* Show user information on forcesave
This commit is contained in:
Natsu Kagami 2024-10-31 14:04:08 +01:00 committed by GitHub
parent c5354e30ad
commit 7d490774e0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
37 changed files with 410 additions and 170 deletions

View file

@ -132,8 +132,8 @@ pub mod builders {
}
}
pub fn mode(&mut self, mode: Mode) -> &mut Self {
self.mode = Some(mode);
pub fn mode(&mut self, mode: impl Into<Option<Mode>>) -> &mut Self {
self.mode = mode.into();
self
}
@ -185,8 +185,8 @@ pub mod builders {
self
}
pub fn mode(&mut self, mode: Mode) -> &mut Self {
self.mode = Some(mode);
pub fn mode(&mut self, mode: impl Into<Option<Mode>>) -> &mut Self {
self.mode = mode.into();
self
}