code: def get_model(method):
      
  
      @wraps(method)
      def wrapper(migrator, model, *args, **kwargs):
          if isinstance(model, str):
              return method(migrator, migrator.orm[model], *args, **kwargs)
          return method(migrator, model, *args, **kwargs)
      return wrapper
docs: Convert string to model class.