case-insensitive NOT FOUND error catching in getDags

Signed-off-by: Daniele.Mazzotta <daniele.mazzotta@tii.ae>
This commit is contained in:
Daniele.Mazzotta
2022-06-23 10:35:50 +04:00
parent aed6b691cb
commit 7bc7b1d376
@@ -82,7 +82,7 @@ export class ApacheAirflowClient implements ApacheAirflowApi {
const response = await Promise.all(
dagIds.map(id => {
return this.fetch<Dag>(`/dags/${id}`).catch(e => {
if (e.message === 'Not Found') {
if (e.message.toUpperCase('en-US') === 'NOT FOUND') {
dagsNotFound.push(id);
} else {
throw e;