          self._populate()
          for app_config in self.app_configs.values():
              if only_installed and not app_config.installed:
                  continue
              if self.available_apps is not None and app_config.label not in self.available_apps:
                  continue
              yield app_config
  
      def get_app_config(self, app_label, only_installed=True):
          """
 
</s> remove         if self.available_apps is not None and app_config.label not in self.available_apps:
 </s> add         if self.available_apps is not None and app_config.name not in self.available_apps: </s> remove                     and app_label not in self.available_apps):
 </s> add                     and app_config.name not in self.available_apps): </s> remove             model_list = [m for m in model_list if m._meta.app_label in self.available_apps]
 </s> add             model_list = [
                m for m in model_list
                if self.app_configs[m._meta.app_label].name in self.available_apps
            ] </s> remove                 model_list = [m for m in model_list if m._meta.app_label in self.available_apps]
 </s> add                 model_list = [
                    m for m in model_list
                    if self.app_configs[m._meta.app_label].name in self.available_apps
                ] </s> remove         if not set(available).issubset(set(settings.INSTALLED_APPS)):
            extra = set(available) - set(settings.INSTALLED_APPS)
 </s> add         available = set(available)
        installed = set(settings.INSTALLED_APPS)
        if not available.issubset(installed):
            if self.available_apps is not None and app_config.name not in self.available_apps:
          self._populate()
          for app_config in self.app_configs.values():
              if only_installed and not app_config.installed:
                  continue
            if self.available_apps is not None and app_config.name not in self.available_apps:
                  continue
              yield app_config
  
      def get_app_config(self, app_label, only_installed=True):
          """
keep keep keep keep replace keep keep keep keep keep
 Simplified handling of available_apps slightly.

It feels more natural for self.available_apps to contain app names (like
INSTALLED_APPS) than app labels, and this is easy to implement now. 
django/apps/cache.py