Fixed bug: image cannot be saved in sd-card