Commit 47053b92 authored by Benjamin Fischer's avatar Benjamin Fischer
Browse files

The codeeditor preview will now retrieve image files only.

parent ecb8ad0c
......@@ -57,7 +57,8 @@ class EditorController(AbstractController):
rfs = self.get("fs")
filelist = rfs.get_file_list(path)
filelist = rfs.get_file_list(path, reverse=True,
filter=map(lambda x: '\.'+x+'\Z', rfs.browser_extensions))
return filelist
......@@ -43,6 +43,7 @@ class FileSystem(object):
def __init__(self):
# allowed extensions
self.allowed_extensions = FileSystem.FILE_EXTENSIONS
self.browser_extensions = FileSystem.BROWSER_EXTENSIONS
def setup(self, basedir=None):
if basedir is None:
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment