Fix migrations to make them work with custom user model.