critical fixes to user foreign key directions