Abp: [Angular App] API error response incorrect when using GetAppConfiguration

Created on 1 Jun 2020  路  1Comment  路  Source: abpframework/abp

I have built the concept of a 'maintenance mode' for my API which returns a status code of 503. When the NGXS action GetAppConfiguration is dispatched the API call fails (which is expected)m but I also expected it to return the original headers and body of the error that was thrown. Instead I get statusCode: 0 which is then incorrectly identified by the error handler.

I have looked at the source code and I see this lines:
https://github.com/abpframework/abp/blob/01f7e75083e12c87f5771491dbe2f233a433779b/npm/ng-packs/packages/core/src/lib/states/config.state.ts#L242-L245

This previously worked in my code on Abp v2.6.0 and was changed in this commit: https://github.com/abpframework/abp/commit/43e9cd2977b037de6cd3180ca120a8ee288ae520#diff-81ce61c98a835356c2c2f135c82a45ea

Is it possible you could return the original error unless it is an error that occurs after the API call?

bug effort-0.5 ui-angular

Most helpful comment

Thanks for reporting 馃憤 The original error response dispatched instead of the wrong error that status code is 0.

>All comments

Thanks for reporting 馃憤 The original error response dispatched instead of the wrong error that status code is 0.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mehdihadeli picture mehdihadeli  路  3Comments

hikalkan picture hikalkan  路  3Comments

wakuflair picture wakuflair  路  3Comments

zsanhong picture zsanhong  路  3Comments

wocar picture wocar  路  3Comments