pass clippy (#575)
This commit is contained in:
1 parent
047ed1e553
commit
daeffd4149
20 files changed
+259
-345
No files matched your search
@@ -189,7 +189,7 @@ pub(super) fn handler(
|
||||
MaximizeToggle => window.set_maximized(!window.is_maximized()),
|
||||
Fullscreen(state) => {
|
||||
if let Some(handle) = window.current_monitor() {
|
||||
window.set_fullscreen(state.then(|| WryFullscreen::Borderless(Some(handle))));
|
||||
window.set_fullscreen(state.then_some(WryFullscreen::Borderless(Some(handle))));
|
||||
}
|
||||
}
|
||||
FocusWindow => window.set_focus(),
|
||||
|
||||
@@ -113,7 +113,7 @@ fn get_mime_from_path(trimmed: &str) -> Result<&str> {
|
||||
return Ok("image/svg+xml");
|
||||
}
|
||||
|
||||
let res = match infer::get_from_path(&trimmed)?.map(|f| f.mime_type()) {
|
||||
let res = match infer::get_from_path(trimmed)?.map(|f| f.mime_type()) {
|
||||
Some(t) if t == "text/plain" => get_mime_by_ext(trimmed),
|
||||
Some(f) => f,
|
||||
None => get_mime_by_ext(trimmed),
|
||||
|
||||
Reference in new issue
Block a user