remove unnecessary media attribute