original_docstring:  Sort the items by the specified keys 
docstring: Sort the items by the specified keys
docstring_tokens: Sort the items by the specified keys
code: def order(items):
              """ Sort the items by the specified keys """
              if order_by is None:
                  return items
              if index is None or order_by != index.range_key:
                  if not isinstance(items, list):
                      items = list(items)
                  items.sort(key=lambda x: x.get(order_by), reverse=reverse)
              return items
code_tokens: def order ( items ) : if order_by is None : return items if index is None or order_by != index . range_key : if not isinstance ( items , list ) : items = list ( items ) items . sort ( key = lambda x : x . get ( order_by ) , reverse = reverse ) return items
short_docstring: Sort the items by the specified keys
short_docstring_tokens: Sort the items by the specified keys
comment: """ Sort the items by the specified keys """