From 4fb8a3f360883fb8542df325c507c217e93f47da Mon Sep 17 00:00:00 2001 From: Andrew Buss Date: Fri, 29 May 2015 00:00:54 -0700 Subject: [PATCH] start handling locked account --- config.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/config.js b/config.js index f38884f..d3d13ab 100644 --- a/config.js +++ b/config.js @@ -26,7 +26,7 @@ angular.module('flashy', [ if (methodName !== 'length') { NodeList.prototype[methodName] = Array.prototype[methodName]; } - }; + } $httpProvider.interceptors.push(function($q) { return { @@ -36,6 +36,12 @@ angular.module('flashy', [ console.log(rejection); $('body').html('
Sorry, the server is not serving requests properly. Try again later
'); } + if(rejection.status == 403){ + console.log(rejection); + if(rejection.data && rejection.data.detail == "Please verify your email before continuing"){ + material + } + } return $q.reject(rejection); } }; -- 1.9.1