def get_sorter_by_args(model, args: list):
    """Get list of SQLAlchemy order_by args from dictionary of arguments.
    """
    sorters = []
    for key in args:
        if key[0] == '-':
            sorters.append(getattr(model, key[1:]).desc())
        else:
            sorters.append(getattr(model, key))
    return sorters