]> source.dussan.org Git - nextcloud-server.git/commitdiff
use json to encode user list
authorRobin Appelman <icewind@owncloud.com>
Wed, 19 Jun 2013 13:02:18 +0000 (15:02 +0200)
committerThomas Mueller <thomas.mueller@tmit.eu>
Thu, 20 Jun 2013 09:59:43 +0000 (11:59 +0200)
apps/files/ajax/scan.php
apps/files/js/files.js

index d58fd69b9f90f0cf664d15efe16dc0c79dbc363d..0706d4e78296b0afdd677e8072cd61266bdcdfce 100644 (file)
@@ -9,7 +9,7 @@ if (isset($_GET['users'])) {
        if ($_GET['users'] === 'all') {
                $users = OC_User::getUsers();
        } else {
-               $users = explode(',', $_GET['users']);
+               $users = json_decode($_GET['users']);
        }
 } else {
        $users = array(OC_User::getUser());
index 27e36eda3b875ad1e4815a3023e41bd99ef220eb..5cb2d67500e70ff61d738db3a71d41e2152abf60 100644 (file)
@@ -813,7 +813,7 @@ function scanFiles(force, dir, users){
                if (users === 'all') {
                        usersString = users;
                } else {
-                       usersString = users.join(',');
+                       usersString = JSON.stringify(users);
                }
                scannerEventSource = new OC.EventSource(OC.filePath('files','ajax','scan.php'),{force: force,dir: dir, users: usersString});
        } else {