reduced code nesting level
Added ability to delete medias from album