diff --git a/src/core/helpers/promise.js b/src/core/helpers/promise.js index 3f77edee2a896886c19ffe08262a65f306d83e0e..f36f5a54cc76ac172e88a1c32fea59b248420d08 100644 --- a/src/core/helpers/promise.js +++ b/src/core/helpers/promise.js @@ -16,7 +16,7 @@ const TASK_APIS = ['request', 'downloadFile', 'uploadFile', 'connectSocket'] const ASYNC_API = ['createBLEConnection'] -const CALLBACK_API_RE = /^on/ +const CALLBACK_API_RE = /^on|^off/ export function isContextApi (name) { return CONTEXT_API_RE.test(name)