@elliemae/pui-app-sdk 5.20.2 → 5.20.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -166,7 +166,7 @@ function AsyncSingleExecution(_target, _propertyKey, descriptor) {
166
166
  return promiseMap.get(key);
167
167
  }
168
168
  const promise = originalMethod.apply(this, args);
169
- if (promise instanceof Promise) {
169
+ if (promise && typeof promise.then === "function") {
170
170
  promiseMap.set(key, promise);
171
171
  promise.catch((e) => e).finally(() => {
172
172
  promiseMap.delete(key);
@@ -136,7 +136,7 @@ function AsyncSingleExecution(_target, _propertyKey, descriptor) {
136
136
  return promiseMap.get(key);
137
137
  }
138
138
  const promise = originalMethod.apply(this, args);
139
- if (promise instanceof Promise) {
139
+ if (promise && typeof promise.then === "function") {
140
140
  promiseMap.set(key, promise);
141
141
  promise.catch((e) => e).finally(() => {
142
142
  promiseMap.delete(key);