Jelajahi Sumber

fix(Register): by default, displayname is set to username and avatar uses initials

Signed-off-by: Jonathan <theflametrooper@gmail.com>
Jonathan 4 tahun lalu
induk
melakukan
e89ca5ee52
1 mengubah file dengan 3 tambahan dan 1 penghapusan
  1. 3 1
      backend/logic/actions/users.js

+ 3 - 1
backend/logic/actions/users.js

@@ -438,6 +438,7 @@ export default {
 					next(null, {
 						_id,
 						username,
+						name: username,
 						email: {
 							address: email,
 							verificationToken
@@ -454,7 +455,8 @@ export default {
 				(user, next) => {
 					UtilsModule.runJob("CREATE_GRAVATAR", { email: user.email.address }, this).then(url => {
 						user.avatar = {
-							type: "gravatar",
+							type: "initials",
+							color: "blue",
 							url
 						};
 						next(null, user);