Skip to content

Commit 9934c49

Browse files
committed
fix ref
1 parent 4234426 commit 9934c49

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

tasks.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,10 @@ def setup(c):
102102
zipstr = BytesIO(urlopen(select2).read())
103103
zipfile_obj = zipfile.ZipFile(zipstr)
104104
zipfile_obj.extractall(STATIC_LIB)
105-
dirname = Path(glob.glob(STATIC_LIB / 'select2-*')[0])
106-
dstdir = ''.join(dirname.rsplit('-', 1)[:-1])
105+
106+
dirname = list(STATIC_LIB.glob('select2-*'))[0]
107+
dstdir = ''.join(dirname.name.rsplit('-', 1)[:-1])
108+
107109
try:
108110
os.rename(dirname, dstdir)
109111
except OSError:

0 commit comments

Comments
 (0)