mirror of
https://github.com/discourse/discourse.git
synced 2025-03-25 10:15:41 +08:00
Ran prettier to clean up some formatting
Follow up to: https://review.discourse.org/t/feature-external-auth-when-redeeming-invites/5152?u=blake
This commit is contained in:
parent
87a0a6664e
commit
d7c73ded14
app/assets/javascripts/discourse
@ -64,16 +64,22 @@ export default Ember.Controller.extend(
|
|||||||
"passwordValidation.failed",
|
"passwordValidation.failed",
|
||||||
"nameValidation.failed",
|
"nameValidation.failed",
|
||||||
"userFieldsValidation.failed",
|
"userFieldsValidation.failed",
|
||||||
"inviteEmailAuthValidation.failed",
|
"inviteEmailAuthValidation.failed"
|
||||||
)
|
)
|
||||||
submitDisabled(
|
submitDisabled(
|
||||||
usernameFailed,
|
usernameFailed,
|
||||||
passwordFailed,
|
passwordFailed,
|
||||||
nameFailed,
|
nameFailed,
|
||||||
userFieldsFailed,
|
userFieldsFailed,
|
||||||
inviteEmailAuthFailed,
|
inviteEmailAuthFailed
|
||||||
) {
|
) {
|
||||||
return usernameFailed || passwordFailed || nameFailed || userFieldsFailed || inviteEmailAuthFailed;
|
return (
|
||||||
|
usernameFailed ||
|
||||||
|
passwordFailed ||
|
||||||
|
nameFailed ||
|
||||||
|
userFieldsFailed ||
|
||||||
|
inviteEmailAuthFailed
|
||||||
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
@computed
|
@computed
|
||||||
|
@ -8,13 +8,18 @@ export default Ember.Mixin.create({
|
|||||||
},
|
},
|
||||||
|
|
||||||
// Validate the name.
|
// Validate the name.
|
||||||
@computed("accountEmail", "authOptions.email", "authOptions.email_valid", "authOptions.auth_provider")
|
@computed(
|
||||||
|
"accountEmail",
|
||||||
|
"authOptions.email",
|
||||||
|
"authOptions.email_valid",
|
||||||
|
"authOptions.auth_provider"
|
||||||
|
)
|
||||||
inviteEmailAuthValidation() {
|
inviteEmailAuthValidation() {
|
||||||
if (
|
if (
|
||||||
!this.siteSettings.enable_invite_only_oauth ||
|
!this.siteSettings.enable_invite_only_oauth ||
|
||||||
(this.siteSettings.enable_invite_only_oauth &&
|
(this.siteSettings.enable_invite_only_oauth &&
|
||||||
this.get("authOptions.email") === this.email &&
|
this.get("authOptions.email") === this.email &&
|
||||||
this.get("authOptions.email_valid"))
|
this.get("authOptions.email_valid"))
|
||||||
) {
|
) {
|
||||||
return InputValidation.create({
|
return InputValidation.create({
|
||||||
ok: true,
|
ok: true,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user