Remove unnecessary method to get the posts per category, just use backref of sqlalchemy.