aboutsummaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/lib/Command
diff options
context:
space:
mode:
authorArthur Schiwon <blizzz@arthur-schiwon.de>2018-12-17 00:31:27 +0100
committerArthur Schiwon <blizzz@arthur-schiwon.de>2018-12-17 00:31:27 +0100
commitfeb5366a428e25ebb6054c4a3d0bc6ea304bb295 (patch)
tree48009bec6d274d23a898899aa78e54903b471b2d /apps/user_ldap/lib/Command
parent9322f5064a03fd523898caaec4414744a76595fc (diff)
downloadnextcloud-server-feb5366a428e25ebb6054c4a3d0bc6ea304bb295.tar.gz
nextcloud-server-feb5366a428e25ebb6054c4a3d0bc6ea304bb295.zip
LDAP clear cache on config modification also when done via API or CLI
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
Diffstat (limited to 'apps/user_ldap/lib/Command')
-rw-r--r--apps/user_ldap/lib/Command/SetConfig.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/user_ldap/lib/Command/SetConfig.php b/apps/user_ldap/lib/Command/SetConfig.php
index db656558efc..cf73874ade8 100644
--- a/apps/user_ldap/lib/Command/SetConfig.php
+++ b/apps/user_ldap/lib/Command/SetConfig.php
@@ -26,6 +26,8 @@
namespace OCA\User_LDAP\Command;
+use OCA\User_LDAP\ConnectionFactory;
+use OCA\User_LDAP\LDAP;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputInterface;
@@ -83,5 +85,8 @@ class SetConfig extends Command {
$configHolder = new Configuration($configID);
$configHolder->$key = $value;
$configHolder->saveConfiguration();
+
+ $connectionFactory = new ConnectionFactory(new LDAP());
+ $connectionFactory->get($configID)->clearCache();
}
}