aboutsummaryrefslogtreecommitdiffstats
path: root/src/stores
diff options
context:
space:
mode:
authorLibravatar haraldox <hnaumann+github@gmail.com>2018-01-22 14:26:31 +0100
committerLibravatar haraldox <hnaumann+github@gmail.com>2018-01-22 14:26:31 +0100
commit945cb5982c4b1b42d17ce91171b6a6740eb3a3e5 (patch)
tree8481794625abecea3230e49f789b7336be512bf0 /src/stores
parentADDED invite button in Account Settings (diff)
downloadferdium-app-945cb5982c4b1b42d17ce91171b6a6740eb3a3e5.tar.gz
ferdium-app-945cb5982c4b1b42d17ce91171b6a6740eb3a3e5.tar.zst
ferdium-app-945cb5982c4b1b42d17ce91171b6a6740eb3a3e5.zip
return to account screen from invite screen
cheap solution because `state` prop of `<Link>` is not being passed to route
Diffstat (limited to 'src/stores')
-rw-r--r--src/stores/UserStore.js6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/stores/UserStore.js b/src/stores/UserStore.js
index 2c164f1bf..476c1f040 100644
--- a/src/stores/UserStore.js
+++ b/src/stores/UserStore.js
@@ -160,15 +160,13 @@ export default class UserStore extends Store {
160 gaEvent('User', 'retrievePassword'); 160 gaEvent('User', 'retrievePassword');
161 } 161 }
162 162
163 @action _invite({ invites }) { 163 @action _invite({ invites, from }) {
164 const data = invites.filter(invite => invite.email !== ''); 164 const data = invites.filter(invite => invite.email !== '');
165 165
166 this.inviteRequest.execute(data); 166 this.inviteRequest.execute(data);
167 167
168 console.log(this.stores.router.location )
169
170 // we do not wait for a server response before redirecting the user 168 // we do not wait for a server response before redirecting the user
171 this.stores.router.push('/'); 169 this.stores.router.push(!!from ? from : '/');
172 170
173 gaEvent('User', 'inviteUsers'); 171 gaEvent('User', 'inviteUsers');
174 } 172 }