creating sort object to allow for variable key value