From c61738991f1c1dc567371c1d4243401f9ad789d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Opio=C5=82a?= <5703111+lopiola@users.noreply.github.com> Date: Thu, 14 Sep 2023 11:44:25 +0200 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Nuwan Goonasekera <2070605+nuwang@users.noreply.github.com> --- lib/galaxy/config/sample/file_sources_conf.yml.sample | 2 +- lib/galaxy/files/sources/onedata.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/galaxy/config/sample/file_sources_conf.yml.sample b/lib/galaxy/config/sample/file_sources_conf.yml.sample index 03ba2f448116..d9032e0bfe88 100644 --- a/lib/galaxy/config/sample/file_sources_conf.yml.sample +++ b/lib/galaxy/config/sample/file_sources_conf.yml.sample @@ -201,6 +201,6 @@ - type: onedata id: onedata1 label: Onedata - doc: Your Onedata files - configure an access token via the user preferences + doc: Your Onedata files - configure an access token via user preferences accessToken: ${user.preferences['onedata|access_token']} onezoneDomain: ${user.preferences['onedata|onezone_domain']} diff --git a/lib/galaxy/files/sources/onedata.py b/lib/galaxy/files/sources/onedata.py index aae705287b29..ee20825703dc 100644 --- a/lib/galaxy/files/sources/onedata.py +++ b/lib/galaxy/files/sources/onedata.py @@ -21,9 +21,9 @@ class OnedataFilesSource(PyFilesystem2FilesSource): def _open_fs(self, user_context=None, opts: Optional[FilesSourceOptions] = None): props = self._serialization_props(user_context) - onezone_domain = props.pop("onezoneDomain", {}) or "" + onezone_domain = props.pop("onezoneDomain", "") or "" onezone_domain = remove_prefix("http://", remove_prefix("https://", onezone_domain)) - access_token = props.pop("accessToken", {}) or "" + access_token = props.pop("accessToken", "") or "" handle = OnedataRESTFS(onezone_domain, access_token) return handle