code: def get_database(self, model):
          
          for router in self.routers:
              r = router.get_database(model)
              if r is not None:
                  return r
          return self.get('default')
docs: Find matching database router