refactoing migrations