don't list directory contents of something that is empty
This commit is contained in:
parent
76de0b10cb
commit
e7f7d7c34d
@ -92,9 +92,10 @@ def RemoveMacFolders(path):
|
|||||||
def GetCssFile(distribusi):
|
def GetCssFile(distribusi):
|
||||||
cssfile = ""
|
cssfile = ""
|
||||||
cssfolder = os.path.join("themes/userthemes", distribusi.distribusiname)
|
cssfolder = os.path.join("themes/userthemes", distribusi.distribusiname)
|
||||||
for filename in os.listdir(cssfolder):
|
if os.path.exists(cssfolder):
|
||||||
if filename.endswith(".css"):
|
for filename in os.listdir(cssfolder):
|
||||||
cssfile = os.path.join(cssfolder, filename)
|
if filename.endswith(".css"):
|
||||||
|
cssfile = os.path.join(cssfolder, filename)
|
||||||
return cssfile
|
return cssfile
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user