summaryrefslogtreecommitdiffstats
path: root/web/react/components
diff options
context:
space:
mode:
authorReed Garmsen <rgarmsen2295@gmail.com>2015-09-21 17:03:08 -0700
committerReed Garmsen <rgarmsen2295@gmail.com>2015-09-21 17:03:08 -0700
commitb4be8eb554d4de1de5b4928a37cb72c34d565487 (patch)
tree90da0008e571282dd9186c7f7240bf2c7b3083db /web/react/components
parentdda30e407aca321f369f27078076d3e05fd28b19 (diff)
downloadchat-b4be8eb554d4de1de5b4928a37cb72c34d565487.tar.gz
chat-b4be8eb554d4de1de5b4928a37cb72c34d565487.tar.bz2
chat-b4be8eb554d4de1de5b4928a37cb72c34d565487.zip
Minor changes to how resend status is passed
Diffstat (limited to 'web/react/components')
-rw-r--r--web/react/components/email_verify.jsx12
1 files changed, 7 insertions, 5 deletions
diff --git a/web/react/components/email_verify.jsx b/web/react/components/email_verify.jsx
index 4d4d489bb..8d3f15525 100644
--- a/web/react/components/email_verify.jsx
+++ b/web/react/components/email_verify.jsx
@@ -10,14 +10,14 @@ export default class EmailVerify extends React.Component {
this.state = {};
}
handleResend() {
- const newAddress = window.location.href.replace('?resend_success=true', '').replace('&resend_success=true', '');
+ const newAddress = window.location.href.replace('&resend_success=true', '');
window.location.href = newAddress + '&resend=true';
}
render() {
var title = '';
var body = '';
var resend = '';
- let resendConfirm = '';
+ var resendConfirm = '';
if (this.props.isVerified === 'true') {
title = global.window.config.SiteName + ' Email Verified';
body = <p>Your email has been verified! Click <a href={this.props.teamURL + '?email=' + this.props.userEmail}>here</a> to log in.</p>;
@@ -32,7 +32,7 @@ export default class EmailVerify extends React.Component {
Resend Email
</button>
);
- if (window.location.href.indexOf('resend_success=true') > -1) {
+ if (this.props.resendSuccess) {
resendConfirm = <div><br /><p className='alert alert-success'><i className='fa fa-check'></i>{' Verification email sent.'}</p></div>;
}
}
@@ -57,10 +57,12 @@ export default class EmailVerify extends React.Component {
EmailVerify.defaultProps = {
isVerified: 'false',
teamURL: '',
- userEmail: ''
+ userEmail: '',
+ resendSuccess: 'false'
};
EmailVerify.propTypes = {
isVerified: React.PropTypes.string,
teamURL: React.PropTypes.string,
- userEmail: React.PropTypes.string
+ userEmail: React.PropTypes.string,
+ resendSuccess: React.PropTypes.string
};