mirror of
https://github.com/zed-industries/zed.git
synced 2024-11-10 05:37:29 +03:00
fmt
This commit is contained in:
parent
f4413b0969
commit
e3f9a01f6b
@ -44,14 +44,14 @@ impl FileAssociations {
|
||||
let this = cx.has_global::<Self>().then(|| cx.global::<Self>())?;
|
||||
|
||||
iife!({
|
||||
let suffix =
|
||||
path.file_name()
|
||||
.and_then(|os_str| os_str.to_str())
|
||||
.and_then(|file_name| {
|
||||
file_name
|
||||
.find('.')
|
||||
.and_then(|dot_index| file_name.get(dot_index + 1..))
|
||||
} )?;
|
||||
let suffix = path
|
||||
.file_name()
|
||||
.and_then(|os_str| os_str.to_str())
|
||||
.and_then(|file_name| {
|
||||
file_name
|
||||
.find('.')
|
||||
.and_then(|dot_index| file_name.get(dot_index + 1..))
|
||||
})?;
|
||||
|
||||
this.suffixes
|
||||
.get(suffix)
|
||||
|
Loading…
Reference in New Issue
Block a user