diff --git a/runtime/main/extend/systemplugin/napi/ohos_multimodalInput_pointer.js b/runtime/main/extend/systemplugin/napi/ohos_multimodalInput_pointer.js index 8c0802b8..abae83d6 100644 --- a/runtime/main/extend/systemplugin/napi/ohos_multimodalInput_pointer.js +++ b/runtime/main/extend/systemplugin/napi/ohos_multimodalInput_pointer.js @@ -32,14 +32,14 @@ export function mockPointer() { isPointerVisible: function (...args) { console.warn("multimodalInput.pointer.isPointerVisible interface mocked in the Previewer." + "How this interface works on the" + " Previewer may be different from that on a real device."); - const len = args.length - if (typeof args[len - 1] === 'function') { - args[len - 1].call(this, paramMock.businessErrorMock, paramMock.paramBooleanMock) - } else { - return new Promise((resolve) => { - resolve(paramMock.paramBooleanMock) - }) - } + const len = args.length + if (typeof args[len - 1] === 'function') { + args[len - 1].call(this, paramMock.businessErrorMock, paramMock.paramBooleanMock) + } else { + return new Promise((resolve) => { + resolve(paramMock.paramBooleanMock) + }) + } }, }; return pointer diff --git a/runtime/main/extend/systemplugin/napi/ohos_zlib.js b/runtime/main/extend/systemplugin/napi/ohos_zlib.js index d0a632c1..c90bd034 100644 --- a/runtime/main/extend/systemplugin/napi/ohos_zlib.js +++ b/runtime/main/extend/systemplugin/napi/ohos_zlib.js @@ -18,7 +18,7 @@ export const MemLevel = { MEM_LEVEL_DEFAULT: 8 }; export const ErrorCode = { - ERROR_CODE_OK: 0, + ERROR_CODE_OK: 1, ERROR_CODE_ERRNO: -1, }; export const CompressLevel = {