Remove directory

main
Bob Mottram 2021-05-30 12:36:20 +01:00
parent 61d0cb1f48
commit ad72231aef
1 changed files with 2 additions and 1 deletions

View File

@ -14,6 +14,7 @@ from utils import copytree
from shutil import copyfile
from shutil import make_archive
from shutil import unpack_archive
from shutil import rmtree
from content import dangerousCSS
@ -64,7 +65,7 @@ def importTheme(baseDir: str, filename: str) -> bool:
os.mkdir(themeDir)
copytree(tempThemeDir, themeDir)
if os.path.isdir(tempThemeDir):
os.remove(tempThemeDir)
rmtree(tempThemeDir)
return os.path.isfile(themeDir + '/theme.json')