defined update function for images model
defined delete function for images model