#948 - optimize migration file