Fixed incorrect from address check for button

refs https://github.com/TryGhost/Ghost/issues/10318

- The check for disabled update button for from address was reversed in this commit - 5d22b788c8
- This updates the check to correctly validate for from address update for disabling the button
This commit is contained in:
Rish 2020-06-30 12:16:48 +05:30
parent 85a77388e2
commit 3f75c2857b

View File

@ -81,7 +81,7 @@ export default Component.extend({
disableUpdateFromAddressButton: computed('fromAddress', function () { disableUpdateFromAddressButton: computed('fromAddress', function () {
const savedFromAddress = this.get('settings.membersFromAddress') || ''; const savedFromAddress = this.get('settings.membersFromAddress') || '';
if (savedFromAddress.includes('@') && this.blogDomain) { if (!savedFromAddress.includes('@') && this.blogDomain) {
return (this.fromAddress === `${savedFromAddress}@${this.blogDomain}`); return (this.fromAddress === `${savedFromAddress}@${this.blogDomain}`);
} }
return (this.fromAddress === savedFromAddress); return (this.fromAddress === savedFromAddress);