fix postgres db migration