function lockr_check_registration in Lockr 7
Same name and namespace in other branches
- 7.2 lockr.module \lockr_check_registration()
Returns if this site is currently registered with Lockr.
Return value
bool TRUE if this site is registered, FALSE if not.
2 calls to lockr_check_registration()
- key_provider_lockr_build_configuration_form in plugins/
key_provider/ lockr.inc - The settings form.
- lockr_admin_form in ./
lockr.admin.inc - Form constructor for Lockr registration form.
File
- ./
lockr.module, line 147 - Hook implementations and callbacks for lockr.
Code
function lockr_check_registration() {
$client = lockr_site_client();
try {
if ($client) {
return $client
->exists();
}
else {
return FALSE;
}
} catch (ServerException $e) {
return FALSE;
} catch (ClientException $e) {
return FALSE;
}
}