media add fixes and validation