From a6b04c462e26ff32d58dfdfdfc9b103636afe1fa Mon Sep 17 00:00:00 2001 From: David Baker Date: Thu, 7 Jul 2016 11:26:35 +0100 Subject: [PATCH] Comment how we're remembering form vals --- src/components/structures/login/Registration.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/components/structures/login/Registration.js b/src/components/structures/login/Registration.js index 4615031760..5126965407 100644 --- a/src/components/structures/login/Registration.js +++ b/src/components/structures/login/Registration.js @@ -54,6 +54,13 @@ module.exports = React.createClass({ return { busy: false, errorText: null, + // We remember the values entered by the user because + // the registration form will be unmounted during the + // course of registration, but if there's an error we + // want to bring back the registration form with the + // values the user enetered still in it. We can keep + // them in this component's state since this component + // persist for the duration of the registration process. formVals: { email: this.props.email, },