code: def allow_migrate(self, db, model):
          
          if model._meta.app_label in self._apps:
              return getattr(model, '_db_alias', model._meta.app_label) == db
          return None
docs: Make sure self._apps go to their own db