In angularjs Make http service in synchronous way using promises : When i hit the url on particular page of the application i want to check whether the page is allow to load or not using the api call, if it is allowed then allow to load that page else redirect to different page

