Skip to content

Commit d1d89b4

Browse files
authored
Merge pull request #1151 from stonebig/master
remove osp from qthelpers.py
2 parents e4149d2 + b7bd8fe commit d1d89b4

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

winpython/qthelpers.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848

4949
import os
5050
import re
51-
import os.path as osp
51+
# import os.path as osp
5252
from pathlib import Path
5353
import sys
5454

@@ -157,10 +157,12 @@ def _process_mime_path(path, extlist):
157157
path = path[5:]
158158
else:
159159
path = path[7:]
160-
if osp.exists(path):
160+
# if osp.exists(path):
161+
if Path(path).exists():
161162
if (
162163
extlist is None
163-
or osp.splitext(path)[1] in extlist
164+
#or osp.splitext(path)[1] in extlist
165+
or Path(path).suffix in extlist
164166
):
165167
return path
166168

0 commit comments

Comments
 (0)