diff --git a/zh-cn/application-dev/media/image-pixelmap-operation.md b/zh-cn/application-dev/media/image-pixelmap-operation.md index a28daf42e51a3f40ed47d11ef69c8e14ba9c13c0..9b11edbf8920bf437f02f3c74e866f97cb9e1807 100644 --- a/zh-cn/application-dev/media/image-pixelmap-operation.md +++ b/zh-cn/application-dev/media/image-pixelmap-operation.md @@ -31,7 +31,7 @@ const readBuffer = new ArrayBuffer(pixelBytesNumber); pixelMap.readPixelsToBuffer(readBuffer).then(() => { console.info('Succeeded in reading image pixel data.'); - }).catch(error => { + }).catch((error : BusinessError) => { console.error('Failed to read image pixel data. And the error is: ' + error); }) @@ -44,7 +44,7 @@ } pixelMap.readPixels(area).then(() => { console.info('Succeeded in reading the image data in the area.'); - }).catch(error => { + }).catch((error : BusinessError) => { console.error('Failed to read the image data in the area. And the error is: ' + error); })