Revert "Fixed media deletion error"

This reverts commit cb907450966f8ce1f82490bf78bfb79399ea02c4.