Use $httpPromise to hook into network respone