Fixed bugs in Edit pages