Adding legacy uid to user and small model fixes