diff --git a/packages/amis-core/src/utils/api.ts b/packages/amis-core/src/utils/api.ts index 91ba69b73..c35ad9352 100644 --- a/packages/amis-core/src/utils/api.ts +++ b/packages/amis-core/src/utils/api.ts @@ -696,6 +696,11 @@ export function isApiOutdated( } nextApi = normalizeApi(nextApi); + prevApi = (prevApi ? normalizeApi(prevApi) : prevApi) as ApiObject; + + if (prevApi && prevApi.url !== nextApi.url) { + return true; + } if (nextApi.autoRefresh === false) { return false; @@ -709,8 +714,6 @@ export function isApiOutdated( let isModified = false; if (prevApi) { - prevApi = normalizeApi(prevApi); - if (nextApi.trackExpression || prevApi.trackExpression) { isModified = tokenize(prevApi.trackExpression || '', prevData) !==