mirror of
https://git.joinplu.me/Plume/Plume.git
synced 2025-01-12 06:05:24 +00:00
Use is_empty() instead of comparing with ""
This commit is contained in:
parent
dfe83aafc5
commit
33fceddc08
1 changed files with 1 additions and 1 deletions
|
@ -401,7 +401,7 @@ pub fn update(
|
|||
user.preferred_theme = form
|
||||
.theme
|
||||
.clone()
|
||||
.and_then(|t| if &t == "" { None } else { Some(t) });
|
||||
.and_then(|t| if t.is_empty() { None } else { Some(t) });
|
||||
user.hide_custom_css = form.hide_custom_css;
|
||||
let _: User = user.save_changes(&*conn).map_err(Error::from)?;
|
||||
|
||||
|
|
Loading…
Reference in a new issue