diff options
| author | gingerBill <bill@gingerbill.org> | 2021-08-15 18:13:56 +0100 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2021-08-15 18:13:56 +0100 |
| commit | 4035fec784fc7e0109d2f8a3d3bbfb5696512de1 (patch) | |
| tree | e961505ebf199e62a9db447a551fc8ace63ade4c /core/path/filepath | |
| parent | b071a07c86f39f3f37ff74dcb05266cf4cbd9540 (diff) | |
Add more uses of `or_return`
Diffstat (limited to 'core/path/filepath')
| -rw-r--r-- | core/path/filepath/match.odin | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/core/path/filepath/match.odin b/core/path/filepath/match.odin index 1446ceb4d..de65a9d41 100644 --- a/core/path/filepath/match.odin +++ b/core/path/filepath/match.odin @@ -298,10 +298,7 @@ _glob :: proc(dir, pattern: string, matches: ^[dynamic]string) -> (m: [dynamic]s for fi in fis { n := fi.name; - matched, err := match(pattern, n); - if err != nil { - return m, err; - } + matched := match(pattern, n) or_return; if matched { append(&m, join(dir, n)); } |