在这里输入图像描述源。Uri不应该是空字符串
await Image.getSize(
uri && uri,
async (width, height) => {
//success
//image still exist in the galory
exist = true;
},
(error) => {
num_messing_files++;
// Failed
// image do no exist any more in the galory [ what does exactly X represent]
}
);
您可以在调用getSize之前检查uri是否为空字符串,而不是在内部执行。
if(uri){
await Image.getSize(...)
}