migrations rewrited