summaryrefslogtreecommitdiffstats
path: root/models/users.js
diff options
context:
space:
mode:
Diffstat (limited to 'models/users.js')
-rw-r--r--models/users.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/models/users.js b/models/users.js
index e85671bc..49c30127 100644
--- a/models/users.js
+++ b/models/users.js
@@ -68,6 +68,16 @@ Users.helpers({
return this.username[0].toUpperCase();
}
},
+
+ getName() {
+ const profile = this.profile || {};
+ return profile.fullname || this.username;
+ },
+
+ getLanguage() {
+ const profile = this.profile || {};
+ return profile.language || 'en';
+ },
});
Users.mutations({