small fix, now it works with any general sqlalchemy model