Move error text to a string file

This commit is contained in:
Dmitrii Metelkin 2016-08-18 21:49:27 +10:00
parent fc66e08628
commit 5f6a3a8c81
2 changed files with 3 additions and 2 deletions

View file

@ -56,7 +56,7 @@ class auth_userkey_external extends external_api {
public static function request_login_url($user) {
if (!is_enabled_auth('userkey')) {
throw new webservice_access_exception('The userkey authentication plugin is disabled.');
throw new webservice_access_exception(get_string('pluginisdisabled', 'auth_userkey'));
}
$context = context_system::instance();

View file

@ -32,4 +32,5 @@ $string['keylifetime'] = 'User key life time';
$string['keylifetime_desc'] = 'Life time in seconds of the each user login key.';
$string['createuser'] = 'Crete user?';
$string['createuser_desc'] = 'If enabled, a new user will be created if fail to find one in LMS.';
$string['userkey:generatekey'] = 'Generate login user key';
$string['userkey:generatekey'] = 'Generate login user key';
$string['pluginisdisabled'] = 'The userkey authentication plugin is disabled.';