1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-31 03:09:44 +02:00

feat(endpoints): enhance offline browsing (#2454)

* feat(api): rewrite error response when trying to query a down endpoint

* feat(interceptors): adding custom backend return code on offline fastfail
This commit is contained in:
baron_l 2018-11-13 04:08:12 +01:00 committed by Anthony Lapenna
parent 0825d05546
commit d455ab3fc7
8 changed files with 12 additions and 7 deletions

View file

@ -6,7 +6,7 @@ angular.module('portainer.app')
interceptor.responseError = responseErrorInterceptor;
function responseErrorInterceptor(rejection) {
if (rejection.status === 502 || rejection.status === -1) {
if (rejection.status === 502 || rejection.status === 503 || rejection.status === -1) {
var endpoint = EndpointProvider.currentEndpoint();
if (endpoint !== undefined) {
var data = endpoint.Snapshots[0].SnapshotRaw.Containers;