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('<div class="card">Sorry, the server is not serving requests properly. Try again later</div>'); } + if(rejection.status == 403){ + console.log(rejection); + if(rejection.data && rejection.data.detail == "Please verify your email before continuing"){ + material + } + } return $q.reject(rejection); } };