summaryrefslogtreecommitdiff
path: root/StoneIsland/www/js/lib/auth/SignupView.js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2016-03-07 16:14:16 +0100
committerJules Laplace <jules@okfoc.us>2016-03-07 16:14:16 +0100
commit3bd704dd83f55a038b1eac699ecdf1fa3bbf8123 (patch)
tree0c39b0649eeda9e45417570c0ef7b36aaa68663a /StoneIsland/www/js/lib/auth/SignupView.js
parentf32930fac442c7948132844a9648879fbd62bab2 (diff)
fixing weirdness
Diffstat (limited to 'StoneIsland/www/js/lib/auth/SignupView.js')
-rwxr-xr-xStoneIsland/www/js/lib/auth/SignupView.js9
1 files changed, 8 insertions, 1 deletions
diff --git a/StoneIsland/www/js/lib/auth/SignupView.js b/StoneIsland/www/js/lib/auth/SignupView.js
index 4645d4d9..8d9cf52d 100755
--- a/StoneIsland/www/js/lib/auth/SignupView.js
+++ b/StoneIsland/www/js/lib/auth/SignupView.js
@@ -103,7 +103,14 @@ var SignupView = FormView.extend({
app.signup.show_errors([[ 'Name', data['Error']['Description'] ]])
}
catch (e) {
- app.signup.show_errors([[ 'Name', "There was an unknown error." ]])
+ switch (data.status) {
+ case 409:
+ app.signup.show_errors([[ 'Email', "Email is already in use." ]])
+ break
+ default:
+ app.signup.show_errors([[ 'Name', "There was an unknown error." ]])
+ break
+ }
}
},