Trustly/Data/data.php
private function sortRecursive(&$data) {
		if(is_array($data)) {
			foreach($data as $k => $v) {
				if(is_array($v)) {
					$this->sortRecursive($v);
					$data[$k] = $v;
				}
			}
			ksort($data);
		}
	}
private function sortRecursive(&$data) {
		if(is_array($data)) {
			foreach($data as $k => $v) {
				if(is_array($v)) {
					$this->sortRecursive($v);
					$data[$k] = $v;
				}
			}
			ksort($data);
		}
	}
private function sortRecursive ( & $ data ) { if ( is_array ( $ data ) ) { foreach ( $ data as $ k => $ v ) { if ( is_array ( $ v ) ) { $ this -> sortRecursive ( $ v ) ; $ data [ $ k ] = $ v ; } } ksort ( $ data ) ; } }
Sort the data in the payload.

Extremely naivly done and does not by far handle all cases, but
handles the case it should, i.e. sort the data for the json
pretty printer

@param mixed $data Payload to sort. Will be sorted in place
Sort the data in the payload .