2
0
Эх сурвалжийг харах

Fix: Error after sending invitation and joining board:
Exception while invoking method 'login' TypeError: Cannot read property 'loginDisabled' of undefined.
Thanks to nztqa ! Closes #1331

Lauri Ojansivu 7 жил өмнө
parent
commit
62e43c0832

+ 3 - 2
CHANGELOG.md

@@ -11,9 +11,10 @@ and fixes the following bugs:
 * [Emoji detection breaks MAC addresses](https://github.com/wekan/wekan/issues/1248);
 * [Emoji detection breaks MAC addresses](https://github.com/wekan/wekan/issues/1248);
 * [Codeblocks should not be scanned for emoji](https://github.com/wekan/wekan/issues/643);
 * [Codeblocks should not be scanned for emoji](https://github.com/wekan/wekan/issues/643);
 * [Whitespace trimming breaks Markdown code block indentation](https://github.com/wekan/wekan/issues/1288):
 * [Whitespace trimming breaks Markdown code block indentation](https://github.com/wekan/wekan/issues/1288):
-* [Helper to list boards for user](https://github.com/wekan/wekan/pull/1327).
+* [Helper to list boards for user](https://github.com/wekan/wekan/pull/1327);
+* [Error after sending invitation and joining board: Exception while invoking method 'login' TypeError: Cannot read property 'loginDisabled' of undefined](https://github.com/wekan/wekan/issues/1331).
 
 
-Thanks to Github users brooksbecton, milesibastos, soohwa, thuanpq and xet7 for their contributions.
+Thanks to Github users brooksbecton, milesibastos, nztqa, soohwa, thuanpq and xet7 for their contributions.
 
 
 # v0.54 2017-11-02 Wekan release
 # v0.54 2017-11-02 Wekan release
 
 

+ 2 - 1
server/authentication.js

@@ -1,7 +1,8 @@
 Meteor.startup(() => {
 Meteor.startup(() => {
 
 
   Accounts.validateLoginAttempt(function (options) {
   Accounts.validateLoginAttempt(function (options) {
-    return !options.user.loginDisabled;
+    const user = options.user || {};
+    return !user.loginDisabled;
   });
   });
 
 
   Authentication = {};
   Authentication = {};