]> source.dussan.org Git - nextcloud-server.git/commitdiff
dont try to create a user with an already existing username
authorRobin Appelman <icewind@owncloud.com>
Mon, 23 Jan 2012 16:34:23 +0000 (17:34 +0100)
committerRobin Appelman <icewind@owncloud.com>
Mon, 23 Jan 2012 16:34:23 +0000 (17:34 +0100)
settings/js/users.js

index 46ab12b857aac7286777378c44f3d6b1728b16e4..c9b1d855db0f7898e7945f7e2ff2c5238827c9ab 100644 (file)
@@ -127,6 +127,9 @@ $(document).ready(function(){
        $('#newuser').submit(function(event){
                event.preventDefault();
                var username=$('#newusername').val();
+               if($('#content table tbody tr').filterAttr('data-uid',username).length>0){
+                       return;
+               }
                if($.trim(username) == '') {
                        alert('Please provide a username!');
                        return false;