Maik Hoepfel
3bc421708a
Use get_registered_model to load User model in Django 1.7
In Django 1.7, get_user_model fails if the app cache isn't ready. As we
have to use it in many places in Oscar, this commit essentially loads
the User model like we load any other model in Oscar. This circumvents
the check for the model registry being ready.
Otherwise, there's major problems trying to avoid imports that trigger
the call to get_user_model (e.g. in forms and test factories) before the
first model is loaded (which then triggers Django's app load sequence).