diff options
Diffstat (limited to 'apps/user_ldap/lib/helper.php')
-rw-r--r-- | apps/user_ldap/lib/helper.php | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/apps/user_ldap/lib/helper.php b/apps/user_ldap/lib/helper.php index 282f4549e3b..fa36e304171 100644 --- a/apps/user_ldap/lib/helper.php +++ b/apps/user_ldap/lib/helper.php @@ -142,33 +142,6 @@ class Helper { } /** - * Truncate's the given mapping table - * - * @param string $mapping either 'user' or 'group' - * @return bool true on success, false otherwise - */ - static public function clearMapping($mapping) { - if($mapping === 'user') { - $table = '`*PREFIX*ldap_user_mapping`'; - } else if ($mapping === 'group') { - $table = '`*PREFIX*ldap_group_mapping`'; - } else { - return false; - } - - $connection = \OC_DB::getConnection(); - $sql = $connection->getDatabasePlatform()->getTruncateTableSQL($table); - $query = \OCP\DB::prepare($sql); - $res = $query->execute(); - - if(\OCP\DB::isError($res)) { - return false; - } - - return true; - } - - /** * extracts the domain from a given URL * @param string $url the URL * @return string|false domain as string on success, false otherwise |