summaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2018-06-29 08:03:43 +0200
committerGitHub <noreply@github.com>2018-06-29 08:03:43 +0200
commit61842f66ee9d5b5ceb5ac925e5c213047d5a5e19 (patch)
treeccc8412bb3e0e3eb3fba7086ef3f3f1b23616685 /core/js
parent89b6ee1a45f165346ddcc9120195714087287b47 (diff)
parentc1682f4228e29cfe9203fed63e7f203dc582482b (diff)
downloadnextcloud-server-61842f66ee9d5b5ceb5ac925e5c213047d5a5e19.tar.gz
nextcloud-server-61842f66ee9d5b5ceb5ac925e5c213047d5a5e19.zip
Merge pull request #5623 from nextcloud/locale-setting
Add user locale/region setting
Diffstat (limited to 'core/js')
-rw-r--r--core/js/js.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/core/js/js.js b/core/js/js.js
index a7dba7981f7..c1713539f4f 100644
--- a/core/js/js.js
+++ b/core/js/js.js
@@ -791,6 +791,15 @@ var OCP = {},
* @return {String} locale string
*/
getLocale: function() {
+ return $('html').data('locale');
+ },
+
+ /**
+ * Returns the user's language
+ *
+ * @returns {String} language string
+ */
+ getLanguage: function () {
return $('html').prop('lang');
},