DevSSY
DevSSY

Reputation: 89

Flutter - FileSystemException: Cannot open file, path = '/path' (OS Error: Operation not permitted, errno = 1) on ios

I am using multi_image_picker:4.5.9 on ios, when i pick up an image and get the path of the file,i want to upload this file to server,but the error comes out.

Upvotes: 6

Views: 8027

Answers (1)

Malek Tubaisaht
Malek Tubaisaht

Reputation: 1387

This error might happened because the file might not be existed yet. so you should check if the file existed or not before opening it.

use file.existsSync() before opening it.

Upvotes: 2

Related Questions