@@ -100,7 +100,7 @@ discard block |
||
| 100 | 100 | $controller->restrictAccess(!in_array($to, ['all', 'never_logged', 'last_6mo']) || Auth::isAdmin()); |
| 101 | 101 | $controller->pageHeader(); |
| 102 | 102 | |
| 103 | -$to_names = implode(I18N::$list_separator, array_map(function(User $user) { return $user->getRealName(); }, recipients($to))); |
|
| 103 | +$to_names = implode(I18N::$list_separator, array_map(function (User $user) { return $user->getRealName(); }, recipients($to))); |
|
| 104 | 104 | |
| 105 | 105 | ?> |
| 106 | 106 | <h2><?= I18N::translate('Send a message') ?></h2> |
@@ -185,13 +185,13 @@ discard block |
||
| 185 | 185 | */ |
| 186 | 186 | function recipients($to) { |
| 187 | 187 | if ($to === 'all') { |
| 188 | - $recipients = User::all(); |
|
| 188 | + $recipients = User::all(); |
|
| 189 | 189 | } elseif ($to === 'last_6mo') { |
| 190 | - $recipients = array_filter(User::all(), function(User $user) { |
|
| 190 | + $recipients = array_filter(User::all(), function (User $user) { |
|
| 191 | 191 | return $user->getPreference('sessiontime') > 0 && WT_TIMESTAMP - $user->getPreference('sessiontime') > 60 * 60 * 24 * 30 * 6; |
| 192 | 192 | }); |
| 193 | 193 | } elseif ($to === 'never_logged') { |
| 194 | - $recipients = array_filter(User::all(), function(User $user) { |
|
| 194 | + $recipients = array_filter(User::all(), function (User $user) { |
|
| 195 | 195 | return $user->getPreference('verified_by_admin') && $user->getPreference('reg_timestamp') > $user->getPreference('sessiontime'); |
| 196 | 196 | }); |
| 197 | 197 | } else { |
@@ -95,7 +95,7 @@ discard block |
||
| 95 | 95 | public function getTabs() { |
| 96 | 96 | $active_tabs = Module::getActiveTabs($this->record->getTree()); |
| 97 | 97 | |
| 98 | - return array_filter($active_tabs, function(ModuleTabInterface $tab) { return $tab->hasTabContent(); }); |
|
| 98 | + return array_filter($active_tabs, function (ModuleTabInterface $tab) { return $tab->hasTabContent(); }); |
|
| 99 | 99 | } |
| 100 | 100 | |
| 101 | 101 | /** |
@@ -143,7 +143,7 @@ discard block |
||
| 143 | 143 | |
| 144 | 144 | if ($n === 0) { |
| 145 | 145 | $content_class = 'collapse show'; |
| 146 | - $aria = 'true'; |
|
| 146 | + $aria = 'true'; |
|
| 147 | 147 | |
| 148 | 148 | // Display gender icon |
| 149 | 149 | foreach ($individual->getFacts('SEX') as $sex_fact) { |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | echo '<dd class="field">', $dummy->getFullName(); |
| 163 | 163 | if ($this->record->canEdit() && !$name_fact->isPendingDeletion()) { |
| 164 | 164 | echo "<div class=\"deletelink\"><a class=\"deleteicon\" href=\"#\" onclick=\"return delete_fact('" . I18N::translate('Are you sure you want to delete this fact?') . "', '" . $this->record->getXref() . "', '" . $name_fact->getFactId() . "');\" title=\"" . I18N::translate('Delete this name') . '"><span class="link_text">' . I18N::translate('Delete this name') . '</span></a></div>'; |
| 165 | - echo '<div class="editlink"><a href="edit_interface.php?action=editname&xref=' . $this->record->getXref() . '&fact_id=' . $name_fact->getFactId() . '&ged=' . $this->record->getTree()->getNameHtml() . '" class="editicon" title="' . I18N::translate('Edit the name') . '"><span class="link_text">' . I18N::translate('Edit the name') . '</span></a></div>'; |
|
| 165 | + echo '<div class="editlink"><a href="edit_interface.php?action=editname&xref=' . $this->record->getXref() . '&fact_id=' . $name_fact->getFactId() . '&ged=' . $this->record->getTree()->getNameHtml() . '" class="editicon" title="' . I18N::translate('Edit the name') . '"><span class="link_text">' . I18N::translate('Edit the name') . '</span></a></div>'; |
|
| 166 | 166 | } |
| 167 | 167 | echo '</dd>'; |
| 168 | 168 | $ct = preg_match_all('/\n2 (\w+) (.*)/', $name_fact->getGedcom(), $nmatch, PREG_SET_ORDER); |
@@ -85,8 +85,7 @@ |
||
| 85 | 85 | // Create the underlying PDO object |
| 86 | 86 | self::$pdo = new PDO( |
| 87 | 87 | (substr($DBHOST, 0, 1) === '/' ? |
| 88 | - "mysql:unix_socket={$DBHOST};dbname={$DBNAME}" : |
|
| 89 | - "mysql:host={$DBHOST};dbname={$DBNAME};port={$DBPORT}" |
|
| 88 | + "mysql:unix_socket={$DBHOST};dbname={$DBNAME}" : "mysql:host={$DBHOST};dbname={$DBNAME};port={$DBPORT}" |
|
| 90 | 89 | ), |
| 91 | 90 | $DBUSER, $DBPASS, |
| 92 | 91 | [ |
@@ -819,7 +819,7 @@ discard block |
||
| 819 | 819 | '<div class="icons">' . |
| 820 | 820 | '<span class="iconz icon-zoomin" title="' . I18N::translate('Zoom in/out on this box.') . '"></span>' . |
| 821 | 821 | '<div class="itr"><i class="icon-pedigree"></i><div class="popup">' . |
| 822 | - '<ul class="' . $personBoxClass . '">' . implode('', array_map(function(Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
| 822 | + '<ul class="' . $personBoxClass . '">' . implode('', array_map(function (Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
| 823 | 823 | '</div>' . |
| 824 | 824 | '</div>' . |
| 825 | 825 | '</div>'; |
@@ -871,7 +871,7 @@ discard block |
||
| 871 | 871 | '<div class="icons">' . |
| 872 | 872 | '<span class="iconz icon-zoomin" title="' . I18N::translate('Zoom in/out on this box.') . '"></span>' . |
| 873 | 873 | '<div class="itr"><i class="icon-pedigree"></i><div class="popup">' . |
| 874 | - '<ul class="' . $personBoxClass . '">' . implode('', array_map(function(Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
| 874 | + '<ul class="' . $personBoxClass . '">' . implode('', array_map(function (Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
| 875 | 875 | '</div>' . |
| 876 | 876 | '</div>' . |
| 877 | 877 | '</div>'; |
@@ -343,7 +343,7 @@ discard block |
||
| 343 | 343 | // Check the script used by each name, so we can match cyrillic with cyrillic, greek with greek, etc. |
| 344 | 344 | $husb_names = []; |
| 345 | 345 | if ($this->husb) { |
| 346 | - $husb_names = array_filter($this->husb->getAllNames(), function(array $x) { return $x['type'] !== '_MARNM'; } ); |
|
| 346 | + $husb_names = array_filter($this->husb->getAllNames(), function (array $x) { return $x['type'] !== '_MARNM'; } ); |
|
| 347 | 347 | } |
| 348 | 348 | // If the individual only has married names, create a dummy birth name. |
| 349 | 349 | if (empty($husb_names)) { |
@@ -359,7 +359,7 @@ discard block |
||
| 359 | 359 | |
| 360 | 360 | $wife_names = []; |
| 361 | 361 | if ($this->wife) { |
| 362 | - $wife_names = array_filter($this->wife->getAllNames(), function(array $x) { return $x['type'] !== '_MARNM'; } ); |
|
| 362 | + $wife_names = array_filter($this->wife->getAllNames(), function (array $x) { return $x['type'] !== '_MARNM'; } ); |
|
| 363 | 363 | } |
| 364 | 364 | // If the individual only has married names, create a dummy birth name. |
| 365 | 365 | if (empty($wife_names)) { |