summaryrefslogtreecommitdiff
path: root/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'index.html')
-rw-r--r--index.html6
1 files changed, 5 insertions, 1 deletions
diff --git a/index.html b/index.html
index a07f16d..e7c7cd9 100644
--- a/index.html
+++ b/index.html
@@ -7,7 +7,11 @@
<script src="/javascript/jquery/jquery.min.js"></script>
<script type="text/javascript">
function authSuccess(data) {
- alert("username: " + data.username + "\ntoken: " + data.token );
+ if (data.status == 'ERROR') {
+ alert("login error: " + data.errorstring);
+ } else {
+ alert("username: " + data.username + "\ntoken: " + data.token );
+ }
}
function authError(req, status, error) {