diff options
Diffstat (limited to 'core/fileAbstraction.py')
-rw-r--r-- | core/fileAbstraction.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/fileAbstraction.py b/core/fileAbstraction.py index 86191b7..141ae0e 100644 --- a/core/fileAbstraction.py +++ b/core/fileAbstraction.py @@ -15,7 +15,7 @@ def listdir(*path): for p in os.listdir(root): if os.path.isdir(os.path.join(root, p)): l += p + "/\n" - + elif os.path.isfile(os.path.join(root, p)): l += p + "\n" #Ignore non-files and non-directories @@ -28,7 +28,7 @@ def listdir(*path): c = c.replace("#", "%23") print("FILE: ", settings.FILES + "listdir/" + c) return urllib.urlopen(settings.FILES + "listdir/" + c).read() - + def dirsAsList(*path): return [d for d in listdir(*path).split("\n") if len(d) > 0 and d[-1] == "/"] |