diff options
author | Arthur Schiwon <blizzz@owncloud.com> | 2014-07-08 00:19:17 +0200 |
---|---|---|
committer | Arthur Schiwon <blizzz@owncloud.com> | 2014-07-08 16:32:01 +0200 |
commit | 3338a0f236a5dc8722faccdaef5e8ab1ea73e841 (patch) | |
tree | ac6ea8b20cb95ee5cb7c776aa8db9bc6e12d0588 /lib/private/appconfig.php | |
parent | 3e3d460729c515e5723587abc30b4d7955173d12 (diff) | |
download | nextcloud-server-3338a0f236a5dc8722faccdaef5e8ab1ea73e841.tar.gz nextcloud-server-3338a0f236a5dc8722faccdaef5e8ab1ea73e841.zip |
port of #9500
don't trigger update from checkPassword, it is already called by userExists, this is enough.
do not write to database when the value is the same
add test cases. also split test classes in a file each, looks like only the first class is being executed
also appconfig shall not write to database if the value is unchanged
Diffstat (limited to 'lib/private/appconfig.php')
-rw-r--r-- | lib/private/appconfig.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/private/appconfig.php b/lib/private/appconfig.php index f20c4a08426..1874d9f2b19 100644 --- a/lib/private/appconfig.php +++ b/lib/private/appconfig.php @@ -183,6 +183,10 @@ class AppConfig implements \OCP\IAppConfig { ); $this->conn->insert('*PREFIX*appconfig', $data); } else { + $oldValue = $this->getValue($app, $key); + if($oldValue === strval($value)) { + return true; + } $data = array( 'configvalue' => $value, ); |