diff options
Diffstat (limited to 'fbin.py')
-rwxr-xr-x | fbin.py | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -204,8 +204,8 @@ class Application(object): if '.' in hash: hash = hash.split('.')[0] file = self.get_file(hash, True) - filename = file.get_path() - if filename == None: + filename = file.get_path() if file else None + if file == None or filename == None: start_response('404 Not Found', [('Content-Type', 'text/html')]) return ['<h1>Not Found</h1><p>The file you requested does not exist.</p>'] |