Fixing migrations and schema