diff options
Diffstat (limited to 'settings/ajax/setlanguage.php')
-rw-r--r-- | settings/ajax/setlanguage.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/settings/ajax/setlanguage.php b/settings/ajax/setlanguage.php index a3988db85bb..a83212927bf 100644 --- a/settings/ajax/setlanguage.php +++ b/settings/ajax/setlanguage.php @@ -11,7 +11,7 @@ if( isset( $_POST['lang'] ) ) { $languageCodes=OC_L10N::findAvailableLanguages(); $lang=$_POST['lang']; if(array_search($lang, $languageCodes) or $lang === 'en') { - OC_Preferences::setValue( OC_User::getUser(), 'core', 'lang', $lang ); + \OC::$server->getConfig()->setUserValue( OC_User::getUser(), 'core', 'lang', $lang ); OC_JSON::success(array("data" => array( "message" => $l->t("Language changed") ))); }else{ OC_JSON::error(array("data" => array( "message" => $l->t("Invalid request") ))); |