Fixes unit test and another potential migration problem using an old alias for foreign key
Merge remote-tracking branch 'origin/6.2.0' into 7.1.0