5302: Simplify r=matklad a=matklad



bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
bors[bot] 2020-07-10 21:57:56 +00:00 committed by GitHub
commit 349c4fceca
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -53,7 +53,7 @@ impl GlobalState {
if change_kind == ChangeKind::Modify {
return false;
}
if path.extension().map(|it| it.to_str()) != Some("rs".into()) {
if path.extension().unwrap_or_default() != "rs" {
return false;
}
if IMPLICIT_TARGET_FILES.iter().any(|it| path.ends_with(it)) {