@@ -414,7 +414,7 @@ discard block |
||
| 414 | 414 | 'health', 'education', 'reform', 'home', 'environment', |
| 415 | 415 | 'transport', 'housing', 'misc', |
| 416 | 416 | ]; |
| 417 | - $sets = array_filter($sets, function ($v) use ($set_descriptions) { |
|
| 417 | + $sets = array_filter($sets, function($v) use ($set_descriptions) { |
|
| 418 | 418 | return array_key_exists($v, $set_descriptions); |
| 419 | 419 | }); |
| 420 | 420 | shuffle($sets); |
@@ -839,16 +839,16 @@ discard block |
||
| 839 | 839 | $recent_speeches = $memcache->get($speeches_key); |
| 840 | 840 | |
| 841 | 841 | if (!$recent_speeches) { |
| 842 | - $searchstring_speeches = "speaker:$person_id -section:wrans"; // Exclude written answers section |
|
| 842 | + $searchstring_speeches = "speaker:$person_id -section:wrans"; // Exclude written answers section |
|
| 843 | 843 | $SEARCHENGINE = new \SEARCHENGINE($searchstring_speeches); |
| 844 | 844 | |
| 845 | 845 | // Search query excluding written questions |
| 846 | 846 | $args_speeches = [ |
| 847 | 847 | 's' => $searchstring_speeches, |
| 848 | - 'p' => 1, // First page |
|
| 849 | - 'num' => 8, // 8 recent speeches/debates |
|
| 850 | - 'pop' => 1, // Disable search logging |
|
| 851 | - 'o' => 'd', // Decending by date order |
|
| 848 | + 'p' => 1, // First page |
|
| 849 | + 'num' => 8, // 8 recent speeches/debates |
|
| 850 | + 'pop' => 1, // Disable search logging |
|
| 851 | + 'o' => 'd', // Decending by date order |
|
| 852 | 852 | ]; |
| 853 | 853 | $results_speeches = $hansard->search($searchstring_speeches, $args_speeches); |
| 854 | 854 | $recent_speeches = serialize($results_speeches['rows'] ?? []); |
@@ -861,7 +861,7 @@ discard block |
||
| 861 | 861 | $recent_wrans = $memcache->get($wrans_key); |
| 862 | 862 | |
| 863 | 863 | if (!$recent_wrans) { |
| 864 | - $searchstring_wrans = "speaker:$person_id section:wrans"; // Only written answers section |
|
| 864 | + $searchstring_wrans = "speaker:$person_id section:wrans"; // Only written answers section |
|
| 865 | 865 | $SEARCHENGINE = new \SEARCHENGINE($searchstring_wrans); |
| 866 | 866 | |
| 867 | 867 | // Search query for written questions only |
@@ -1186,7 +1186,7 @@ discard block |
||
| 1186 | 1186 | |
| 1187 | 1187 | $lang = LANGUAGE; |
| 1188 | 1188 | |
| 1189 | - $reg = ['chamber_registers' => [] ]; |
|
| 1189 | + $reg = ['chamber_registers' => []]; |
|
| 1190 | 1190 | |
| 1191 | 1191 | foreach ($valid_chambers as $chamber) { |
| 1192 | 1192 | $key = 'person_regmem_' . $chamber . '_' . $lang; |
@@ -1201,7 +1201,7 @@ discard block |
||
| 1201 | 1201 | } |
| 1202 | 1202 | |
| 1203 | 1203 | // sort chamber registers by published_date |
| 1204 | - uasort($reg['chamber_registers'], function ($a, $b) { |
|
| 1204 | + uasort($reg['chamber_registers'], function($a, $b) { |
|
| 1205 | 1205 | return $a->published_date <=> $b->published_date; |
| 1206 | 1206 | }); |
| 1207 | 1207 | |
@@ -1296,7 +1296,7 @@ discard block |
||
| 1296 | 1296 | } |
| 1297 | 1297 | |
| 1298 | 1298 | foreach ($mreg as $reg) { |
| 1299 | - $data['members'][] = [ |
|
| 1299 | + $data['members'][] = [ |
|
| 1300 | 1300 | 'url' => '/' . $rep_type . '/?p=' . $reg['person_id'], |
| 1301 | 1301 | 'name' => $reg['given_name'] . ' ' . $reg['family_name'], |
| 1302 | 1302 | ]; |