Completed
Push — openstreetmap ( 88502a...0f3d44 )
by Greg
11:12 queued 03:39
created
app/FactLocation.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
  * You should have received a copy of the GNU General Public License
14 14
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 15
  */
16
-declare(strict_types = 1);
16
+declare(strict_types=1);
17 17
 
18 18
 namespace Fisharebest\Webtrees;
19 19
 
Please login to merge, or discard this patch.
resources/views/modules/openstreetmap/event-sidebar.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -9,14 +9,14 @@
 block discarded – undo
9 9
     </a>
10 10
 <?php endif ?>
11 11
 
12
-<?php if($value): ?>
12
+<?php if ($value): ?>
13 13
     <span>
14 14
         <?= $value ?>
15 15
     </span>
16 16
 <?php endif ?>
17 17
 
18 18
 <div>
19
-    <?php if($addtag): ?>
19
+    <?php if ($addtag): ?>
20 20
         <?= GedcomTag::getLabel('BIRT') ?>:
21 21
     <?php endif ?>
22 22
     <?= $date ?>
Please login to merge, or discard this patch.
resources/views/modules/openstreetmap/admin-import-form.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@  discard block
 block discarded – undo
6 6
 
7 7
 <h3><?= $title ?></h3>
8 8
 <form id="upload_form" method="post" enctype="multipart/form-data" action="<?=
9
-    e(route('admin-module',[
9
+    e(route('admin-module', [
10 10
         'module' => $module,
11 11
         'action' => 'AdminImport',
12 12
     ])) ?>">
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
 				</div>
30 30
 				<select id="serverfile" name="serverfile" class="form-control">
31 31
                     <option class='custom-select' selected disabled value=''><?= I18N::translate('choose a file&hellip;') ?></option>
32
-                    <?php foreach($files as $file): ?>
32
+                    <?php foreach ($files as $file): ?>
33 33
                         <option value="<?= e($file) ?>"><?= $file ?></option>
34 34
                     <?php endforeach ?>
35 35
 				</select>
Please login to merge, or discard this patch.
resources/views/modules/openstreetmap/admin-places.php 1 patch
Spacing   +3 added lines, -5 removed lines patch added patch discarded remove patch
@@ -67,12 +67,10 @@  discard block
 block discarded – undo
67 67
                 </a>
68 68
             </td>
69 69
 			<td>
70
-				<?= ($place->pl_lati === null) ? FontAwesome::decorativeIcon('warning') :
71
-                    strtr($place->pl_lati, ['N' => '', 'S' => '-', ',' => '.']) ?>
70
+				<?= ($place->pl_lati === null) ? FontAwesome::decorativeIcon('warning') : strtr($place->pl_lati, ['N' => '', 'S' => '-', ',' => '.']) ?>
72 71
 			</td>
73 72
 			<td>
74
-				<?= ($place->pl_long === null) ? FontAwesome::decorativeIcon('warning') :
75
-                    strtr($place->pl_long, ['E' => '', 'W' => '-', ',' => '.']) ?>
73
+				<?= ($place->pl_long === null) ? FontAwesome::decorativeIcon('warning') : strtr($place->pl_long, ['E' => '', 'W' => '-', ',' => '.']) ?>
76 74
 			</td>
77 75
 			<td>
78 76
 				<?= $place->pl_long === null ? FontAwesome::decorativeIcon('warning') : $place->pl_zoom ?>
@@ -194,7 +192,7 @@  discard block
 block discarded – undo
194 192
 	</tfoot>
195 193
 </table>
196 194
 
197
-<form method="POST" action="<?= e(route('admin-module',[
195
+<form method="POST" action="<?= e(route('admin-module', [
198 196
 		'module' => $module,
199 197
 		'action' => 'AdminImportPlaces'
200 198
 	])) ?>">
Please login to merge, or discard this patch.
resources/views/media-page.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -10,13 +10,13 @@
 block discarded – undo
10 10
 
11 11
 <?php if ($media->isPendingDeletion()): ?>
12 12
 	<?php if (Auth::isModerator($media->getTree())): ?>
13
-		<?= view('alerts/warning-dissmissible', ['alert' => /* I18N: %1$s is “accept”, %2$s is “reject”. These are links. */ I18N::translate( 'This media object has been deleted. You should review the deletion and then %1$s or %2$s it.', '<a href="#" class="alert-link" onclick="accept_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the deletion and then accept or reject it.', 'accept') . '</a>', '<a href="#" class="alert-link" onclick="reject_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the deletion and then accept or reject it.', 'reject') . '</a>') . ' ' . FunctionsPrint::helpLink('pending_changes')]) ?>
13
+		<?= view('alerts/warning-dissmissible', ['alert' => /* I18N: %1$s is “accept”, %2$s is “reject”. These are links. */ I18N::translate('This media object has been deleted. You should review the deletion and then %1$s or %2$s it.', '<a href="#" class="alert-link" onclick="accept_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the deletion and then accept or reject it.', 'accept') . '</a>', '<a href="#" class="alert-link" onclick="reject_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the deletion and then accept or reject it.', 'reject') . '</a>') . ' ' . FunctionsPrint::helpLink('pending_changes')]) ?>
14 14
 	<?php elseif (Auth::isEditor($media->getTree())): ?>
15 15
 		<?= view('alerts/warning-dissmissible', ['alert' => I18N::translate('This media object has been deleted. The deletion will need to be reviewed by a moderator.') . ' ' . FunctionsPrint::helpLink('pending_changes')]) ?>
16 16
 	<?php endif ?>
17 17
 <?php elseif ($media->isPendingAddition()): ?>
18 18
 	<?php if (Auth::isModerator($media->getTree())): ?>
19
-		<?= view('alerts/warning-dissmissible', ['alert' => /* I18N: %1$s is “accept”, %2$s is “reject”. These are links. */ I18N::translate( 'This media object has been edited. You should review the changes and then %1$s or %2$s them.', '<a href="#" class="alert-link" onclick="accept_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the changes and then accept or reject them.', 'accept') . '</a>', '<a href="#" class="alert-link" onclick="reject_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the changes and then accept or reject them.', 'reject') . '</a>' ) . ' ' . FunctionsPrint::helpLink('pending_changes')]) ?>
19
+		<?= view('alerts/warning-dissmissible', ['alert' => /* I18N: %1$s is “accept”, %2$s is “reject”. These are links. */ I18N::translate('This media object has been edited. You should review the changes and then %1$s or %2$s them.', '<a href="#" class="alert-link" onclick="accept_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the changes and then accept or reject them.', 'accept') . '</a>', '<a href="#" class="alert-link" onclick="reject_changes(\'' . e($media->getXref()) . '\', \'' . e($media->getTree()->getName()) . '\');">' . I18N::translateContext('You should review the changes and then accept or reject them.', 'reject') . '</a>') . ' ' . FunctionsPrint::helpLink('pending_changes')]) ?>
20 20
 	<?php elseif (Auth::isEditor($media->getTree())): ?>
21 21
 		<?= view('alerts/warning-dissmissible', ['alert' => I18N::translate('This media object has been edited. The changes need to be reviewed by a moderator.') . ' ' . FunctionsPrint::helpLink('pending_changes')]) ?>
22 22
 	<?php endif ?>
Please login to merge, or discard this patch.
app/Location.php 1 patch
Spacing   +6 added lines, -8 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
  * You should have received a copy of the GNU General Public License
14 14
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 15
  */
16
-declare(strict_types = 1);
16
+declare(strict_types=1);
17 17
 
18 18
 namespace Fisharebest\Webtrees;
19 19
 
@@ -30,14 +30,14 @@  discard block
 block discarded – undo
30 30
 	 * @param array $record
31 31
 	 * @throws \Exception
32 32
 	 */
33
-	public function __construct($gedcomName, $record=[]) {
33
+	public function __construct($gedcomName, $record = []) {
34 34
 		$tmp = $this->getRecordFromName($gedcomName);
35 35
 		if ($tmp !== null) {
36 36
 			$this->record = $tmp;
37 37
 		} elseif (!empty($record)) {
38
-			$this->record = (object)$record;
38
+			$this->record = (object) $record;
39 39
 		} else {
40
-			$this->record = (object)[
40
+			$this->record = (object) [
41 41
 				'fqpn'         => '',
42 42
 				'pl_id'        => 0,
43 43
 				'pl_parent_id' => 0,
@@ -67,8 +67,7 @@  discard block
 block discarded – undo
67 67
 		switch ($format) {
68 68
 			case 'signed':
69 69
 				return $this->record->pl_lati ?
70
-					(float)strtr($this->record->pl_lati, ['N' => '', 'S' => '-', ',' => '.']) :
71
-					$this->record->pl_lati;
70
+					(float) strtr($this->record->pl_lati, ['N' => '', 'S' => '-', ',' => '.']) : $this->record->pl_lati;
72 71
 			default:
73 72
 				return $this->record->pl_lati;
74 73
 		}
@@ -83,8 +82,7 @@  discard block
 block discarded – undo
83 82
 		switch ($format) {
84 83
 			case 'signed':
85 84
 				return $this->record->pl_long ?
86
-					(float)strtr($this->record->pl_long, ['E' => '', 'W' => '-', ',' => '.']) :
87
-					$this->record->pl_long;
85
+					(float) strtr($this->record->pl_long, ['E' => '', 'W' => '-', ',' => '.']) : $this->record->pl_long;
88 86
 			default:
89 87
 				return $this->record->pl_long;
90 88
 		}
Please login to merge, or discard this patch.
app/Http/Controllers/PlaceHierarchyController.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -50,14 +50,14 @@  discard block
 block discarded – undo
50 50
 		$osm_module = Module::getModuleByName(self::MAP_MODULE);
51 51
 		$method     = 'assets';
52 52
 		$showmap    = $osm_module &&
53
-			(bool)$osm_module->getPreference('place_hierarchy') &&
53
+			(bool) $osm_module->getPreference('place_hierarchy') &&
54 54
 			method_exists($osm_module, $method) &&
55 55
 			strpos($action, 'hierarchy') === 0;
56 56
 		$data       = null;
57 57
 		$note       = false;
58 58
 
59 59
 		if ($showmap) {
60
-			$note    = true;
60
+			$note = true;
61 61
 			$content .= view('modules/openstreetmap/map',
62 62
 				[
63 63
 					'assets' => $osm_module->$method(),
@@ -70,14 +70,14 @@  discard block
 block discarded – undo
70 70
 
71 71
 		switch ($action) {
72 72
 			case 'list':
73
-				$nextaction      = ['hierarchy' => I18N::translate('Show place hierarchy')];
74
-				$content         .= view('place-list', $this->getList($tree));
73
+				$nextaction = ['hierarchy' => I18N::translate('Show place hierarchy')];
74
+				$content .= view('place-list', $this->getList($tree));
75 75
 				break;
76 76
 			case 'hierarchy':
77 77
 			case 'hierarchy-e':
78 78
 				$nextaction      = ['list' => I18N::translate('Show all places in a list')];
79 79
 				$data            = $this->getHierarchy($tree, $place, $parent);
80
-				$content         .= (null === $data || $showmap) ? '' : view('place-hierarchy', $data);
80
+				$content .= (null === $data || $showmap) ? '' : view('place-hierarchy', $data);
81 81
 				if (null === $data || $action === 'hierarchy-e') {
82 82
 					$content .= view('place-events', $this->getEvents($tree, $place));
83 83
 				}
@@ -117,7 +117,7 @@  discard block
 block discarded – undo
117 117
 
118 118
 		return
119 119
 			[
120
-				'columns' => array_chunk($list_places, (int)ceil($numfound / $divisor)),
120
+				'columns' => array_chunk($list_places, (int) ceil($numfound / $divisor)),
121 121
 			];
122 122
 	}
123 123
 
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
 				[
140 140
 					'tree'      => $tree,
141 141
 					'col_class' => "w-" . ($divisor === 2 ? "25" : "50"),
142
-					'columns'   => array_chunk($child_places, (int)ceil($numfound / $divisor)),
142
+					'columns'   => array_chunk($child_places, (int) ceil($numfound / $divisor)),
143 143
 					'place'     => $place,
144 144
 					'parent'    => $parent,
145 145
 				];
Please login to merge, or discard this patch.
app/Http/Controllers/FamilyBookChartController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -170,7 +170,7 @@
 block discarded – undo
170 170
 				echo '<table cellspacing="0" cellpadding="0" border="0" >';
171 171
 				foreach ($children as $i => $child) {
172 172
 					echo '<tr><td>';
173
-					$kids    = $this->printDescendency($child, $generation + 1);
173
+					$kids = $this->printDescendency($child, $generation + 1);
174 174
 					$numkids += $kids;
175 175
 					echo '</td>';
176 176
 					// Print the lines
Please login to merge, or discard this patch.
resources/views/admin/trees.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
 				</div>
30 30
 				<div id="card-tree-content-<?= $managed_tree->getTreeId() ?>" class="collapse<?= $managed_tree == $tree || $managed_tree->getPreference('imported') === '0' ? ' show' : '' ?>" role="tabpanel" aria-labelledby="panel-tree-header-<?= $managed_tree->getTreeId() ?>">
31 31
 					<div class="card-body">
32
-						<?php $importing = Database::prepare( "SELECT 1 FROM `##gedcom_chunk` WHERE gedcom_id = ? AND imported = '0' LIMIT 1" )->execute([$managed_tree->getTreeId()])->fetchOne() ?>
32
+						<?php $importing = Database::prepare("SELECT 1 FROM `##gedcom_chunk` WHERE gedcom_id = ? AND imported = '0' LIMIT 1")->execute([$managed_tree->getTreeId()])->fetchOne() ?>
33 33
 						<?php if ($importing): ?>
34 34
 							<div id="import<?= $managed_tree->getTreeId() ?>" class="col-xs-12">
35 35
 								<div class="progress">
Please login to merge, or discard this patch.