Factored out and unit tested the "edit page settings" route, which was itself fine but revealed a bug in apos.updateRedirect