Fix backend media rewrite.