'Used to repopulate AppCache after fiddling with INSTALLED_APPS.'

def _redo_app_cache(self):

    cache.loaded = False
    cache.handled = (set() if (django.VERSION >= (1, 6)) else {})
    cache.postponed = []
    cache.app_store = SortedDict()
    cache.app_models = SortedDict()
    cache.app_errors = {}
    cache._populate()
