Beautify migration code