]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix: Reset selected backend when adding a new storage
authorDaniel Calviño Sánchez <danxuliu@gmail.com>
Mon, 29 Jul 2024 10:21:13 +0000 (12:21 +0200)
committerDaniel Calviño Sánchez <danxuliu@gmail.com>
Thu, 5 Sep 2024 02:18:38 +0000 (04:18 +0200)
As a new storage is added by selecting a backend the selected backend
needs to be reset. Otherwise it is not possible to add another storage
with the same backend.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
apps/files_external/js/settings.js

index 390fa8fea8cca3e856867c77c551aca4468dcbd7..1225115eff2a41944d08e8f290560c3575e272fa 100644 (file)
@@ -770,6 +770,8 @@ MountConfigListView.prototype = _.extend({
                storageConfig.backend = $target.val();
                $tr.find('.mountPoint input').val('');
 
+               $tr.find('.selectBackend').prop('selectedIndex', 0)
+
                var onCompletion = jQuery.Deferred();
                $tr = this.newStorage(storageConfig, onCompletion);
                $tr.find('.applicableToAllUsers').prop('checked', false).trigger('change');