Removed unnecessary DB call. Fixed redirection issue after deleting many images at once