1. Jeffrey Tratner
  2. sqlalchemy

Commits

Mike Bayer  committed 8c06387

- use "True" to indicate self-inspects, remove a lambda call

  • Participants
  • Parent commits 16c9a1a
  • Branches default

Comments (0)

Files changed (1)

File lib/sqlalchemy/inspection.py

View file
     for cls in type_.__mro__:
         if cls in _registrars:
             reg = _registrars[cls]
+            if reg is True:
+                return subject
             ret = reg(subject)
             if ret is not None:
                 break
     return decorate
 
 def _self_inspects(*types):
-    _inspects(*types)(lambda subject:subject)
+    _inspects(*types)(True)