Fixed the Entity Framework repository among other things.
Moving to Entity Framework migrations as well.