I want to delete the directory which was created by the mount uploader manually. I have ArtistProduct and ArtistImage models. I want to delete the images which is stored in the file via artist product controller. I tried carrier this:
@art_images=ArtistImage.where("product_id=?",params[:id])
@art_images.each do |img|
img.remove_image!
end
@art_images.delete_all
But Image is not getting deleting. Please help me
Try this, it will delete directory from your file system.