fixing media upload error