Commits

Lee McFadden committed 51cfa13

Added support for SQLAlchemy 0.6 in paginate.py

Comments (0)

Files changed (1)

webhelpers/paginate.py

     if isinstance(obj, (list, tuple)):
         return obj
     # Is SQLAlchemy 0.4 available? (0.3 is not supported - sorry)
-    if sqlalchemy_available.startswith('0.4') or sqlalchemy_available.startswith('0.5'):
+    if sqlalchemy_available.startswith('0.4') or sqlalchemy_available.startswith('0.5')\
+       or sqlalchemy_available.startswith('0.6'):
         # Is the collection a query?
         if isinstance(obj, sqlalchemy.orm.query.Query):
             return _SQLAlchemyQuery(obj)