Fix unity lifetime for EF