bbovenzi commented on code in PR #61588:
URL: https://github.com/apache/airflow/pull/61588#discussion_r2896856092
##########
airflow-core/src/airflow/ui/src/queries/useDeleteDag.ts:
##########
@@ -34,6 +34,16 @@ export const useDeleteDag = ({
const { t: translate } = useTranslation();
const onError = (error: Error) => {
+ // Get status from error
+ const status =
+ (error as unknown as { status?: number }).status ??
+ (error as unknown as { response?: { status?: number }
}).response?.status;
Review Comment:
I feel like we should pull this out into a util instead of copy-pasting this
code all over.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]