#NEWLINE# def get_posts( p_filter = None , p_order = None ) : #NEWLINE# #INDENT# 'Shortcut function to get a query result filtered by given filter,\n    ordered by given order\n\n    :param p_filter: SQLAlchemy filter statement\n    :param p_order: SQLAlchemy p_order statement\n    ' #NEWLINE# ret = posts_base ( ) #NEWLINE# if ( p_filter is not None ) : #NEWLINE# #INDENT# ret = ret . filter ( p_filter ) #NEWLINE# #UNINDENT# if ( p_order is not None ) : #NEWLINE# #INDENT# ret = ret . order_by ( p_order ) #NEWLINE# #UNINDENT# return p_order