#NEWLINE# def list( self , sort_by = None ) : #NEWLINE# #INDENT# 'List all leases.' #NEWLINE# leases = self . _get ( '/leases' , 'leases' ) #NEWLINE# if sort_by : #NEWLINE# #INDENT# leases = sorted ( leases , key = ( lambda l : l [ sort_by ] ) ) #NEWLINE# #UNINDENT# return leases