You are here

private function ViewsEFFieldsetData::sortByWeight in Views Exposed Form Fieldset 7

Internal function used to sort array items by weight.

File

includes/ViewsEFFieldsetData.php, line 81
ViewsEFFieldsetData class file.

Class

ViewsEFFieldsetData
Class ViewsEFFieldsetData

Code

private function sortByWeight($a, $b) {
  if ($a['item']['weight'] == $b['item']['weight']) {
    return 0;
  }
  return $a['item']['weight'] < $b['item']['weight'] ? -1 : 1;
}