@@ -455,7 +455,7 @@ discard block |
||
| 455 | 455 | return; |
| 456 | 456 | } |
| 457 | 457 | |
| 458 | - $cons_sort = function ($a, $b) { |
|
| 458 | + $cons_sort = function($a, $b) { |
|
| 459 | 459 | if ($a['rep_name'] == $b['rep_name']) { |
| 460 | 460 | if ($a['constituency'] == $b['constituency']) { |
| 461 | 461 | if ($a['member']->family_name == $b['member']->family_name) { |
@@ -532,7 +532,7 @@ discard block |
||
| 532 | 532 | foreach ($this->data['member_constituencies'] as $pid) { |
| 533 | 533 | try { |
| 534 | 534 | $MEMBER = new \MySociety\TheyWorkForYou\Member(['person_id' => $pid]); |
| 535 | - $cons[] = [ 'member' => $MEMBER, 'constituency' => $MEMBER->constituency, 'rep_name' => $MEMBER->getMostRecentMembership()['rep_name'] ]; |
|
| 535 | + $cons[] = ['member' => $MEMBER, 'constituency' => $MEMBER->constituency, 'rep_name' => $MEMBER->getMostRecentMembership()['rep_name']]; |
|
| 536 | 536 | } catch (\MySociety\TheyWorkForYou\MemberException $e) { |
| 537 | 537 | // do nothing |
| 538 | 538 | } |
@@ -550,12 +550,12 @@ discard block |
||
| 550 | 550 | $q = $db->query("SELECT person_id FROM member WHERE constituency = :constituency AND house = :house and left_reason = 'still_in_office'", [':constituency' => $constituency, ':house' => $house]); |
| 551 | 551 | foreach ($q as $row) { |
| 552 | 552 | $MEMBER = new \MySociety\TheyWorkForYou\Member(['person_id' => $row['person_id'], 'house' => $house]); |
| 553 | - $cons[] = [ 'member' => $MEMBER, 'constituency' => $constituency, 'rep_name' => $MEMBER->getMostRecentMembership()['rep_name'] ]; |
|
| 553 | + $cons[] = ['member' => $MEMBER, 'constituency' => $constituency, 'rep_name' => $MEMBER->getMostRecentMembership()['rep_name']]; |
|
| 554 | 554 | } |
| 555 | 555 | |
| 556 | 556 | } else { |
| 557 | 557 | $MEMBER = new \MySociety\TheyWorkForYou\Member(['constituency' => $constituency, 'house' => $house]); |
| 558 | - $cons[] = [ 'member' => $MEMBER, 'constituency' => $constituency ]; |
|
| 558 | + $cons[] = ['member' => $MEMBER, 'constituency' => $constituency]; |
|
| 559 | 559 | } |
| 560 | 560 | } catch (\MySociety\TheyWorkForYou\MemberException $e) { |
| 561 | 561 | // do nothing |
@@ -721,7 +721,7 @@ discard block |
||
| 721 | 721 | if ($this->data['pid']) { |
| 722 | 722 | $criteria .= " speaker:" . $this->data['pid']; |
| 723 | 723 | } |
| 724 | - $this->data['search_results'] = $this->getRecentResults($criteria); |
|
| 724 | + $this->data['search_results'] = $this->getRecentResults($criteria); |
|
| 725 | 725 | } |
| 726 | 726 | |
| 727 | 727 | $this->data['criteria'] = $criteria; |
@@ -801,7 +801,7 @@ discard block |
||
| 801 | 801 | } |
| 802 | 802 | if ($add) { |
| 803 | 803 | $this->data['all_keywords'][] = $term; |
| 804 | - $alert['search_results'] = $this->getRecentResults($alert["raw"]); |
|
| 804 | + $alert['search_results'] = $this->getRecentResults($alert["raw"]); |
|
| 805 | 805 | $this->data['keyword_alerts'][] = $alert; |
| 806 | 806 | } |
| 807 | 807 | } |