From 0bd10d27c69514fe264c4777f98f25e9a58179e5 Mon Sep 17 00:00:00 2001 From: Ekaterina Fedorova Date: Tue, 12 Nov 2013 16:15:52 +0400 Subject: [PATCH] Fix file deletion Return 500 in case of exception Change-Id: Ief08e3012316dc110eaf6fc85d4421683372bc61 --- muranorepository/api/v1.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/muranorepository/api/v1.py b/muranorepository/api/v1.py index 9c32acc..a25ceb2 100644 --- a/muranorepository/api/v1.py +++ b/muranorepository/api/v1.py @@ -122,9 +122,8 @@ def delete_directory_or_file(data_type, path): if os.path.isfile(result_path): try: os.remove(result_path) - api.update_cache(data_type) except Exception: - abort(404) + abort(500) else: try: # enable to delete only empty directories