Sfoglia il codice sorgente

[filebrowser] Check for abfs:// in remote_storage_home and remove RAZ check (#3077)

- RAZ check is done when handling user directories, so this method is much cleaner now.
Harsh Gupta 3 anni fa
parent
commit
726d793adc
1 ha cambiato i file con 3 aggiunte e 3 eliminazioni
  1. 3 3
      desktop/libs/azure/src/azure/abfs/__init__.py

+ 3 - 3
desktop/libs/azure/src/azure/abfs/__init__.py

@@ -182,10 +182,10 @@ def get_home_dir_for_abfs(user=None):
   except:
     remote_home_abfs = 'abfs://'
 
-  # Check from remote_storage_home config only for RAZ env
-  if RAZ.IS_ENABLED.get() and hasattr(REMOTE_STORAGE_HOME, 'get') and REMOTE_STORAGE_HOME.get():
+  if hasattr(REMOTE_STORAGE_HOME, 'get') and REMOTE_STORAGE_HOME.get() and REMOTE_STORAGE_HOME.get().startswith('abfs://'):
     remote_home_abfs = REMOTE_STORAGE_HOME.get()
-    remote_home_abfs = _handle_user_dir_raz(user, remote_home_abfs)
+
+  remote_home_abfs = _handle_user_dir_raz(user, remote_home_abfs)
 
   return remote_home_abfs