Skip to content

Commit

Permalink
fix: fix runtime err [can't read property 'success' of undefined]
Browse files Browse the repository at this point in the history
  • Loading branch information
anotherso1a committed Mar 4, 2024
1 parent 0ed5fa5 commit a2e3c80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/api-proxy/src/common/js/promisify.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ function promisify (listObj, whiteList, customBlackList) {

result[key] = function (...args) {
const obj = args[0]
if (promisifyFilter(key) && !(obj.success || obj.fail || obj.complete)) {
if (promisifyFilter(key) && !(obj?.success || obj?.fail || obj?.complete)) {
if (!args[0]) {
args.unshift({ success: noop, fail: noop })
}
Expand Down

0 comments on commit a2e3c80

Please sign in to comment.