Pārlūkot izejas kodu

HUE-6795 [fb] Fix minor logic error in trash directory creation (#554)

Re-places the logic accidentally removed by HUE-1212

https://github.com/cloudera/hue/pull/554
Harsh J 8 gadi atpakaļ
vecāks
revīzija
bdcf582
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      desktop/libs/hadoop/src/hadoop/fs/webhdfs.py

+ 1 - 1
desktop/libs/hadoop/src/hadoop/fs/webhdfs.py

@@ -270,7 +270,7 @@ class WebHdfs(Hdfs):
 
   def _ensure_current_trash_directory(self, path):
     """Create trash directory for a user if it doesn't exist."""
-    if self.exists(self.current_trash_path(path)):
+    if not self.exists(self.current_trash_path(path)):
       self.mkdir(self.current_trash_path(path))
     return self.current_trash_path(path)