Author: Andreas Möller (localheinz)
Committer: GitHub (web-flow)
Pusher: cmb69
Date: 2022-07-11T20:13:00+02:00

Commit: 
https://github.com/php/web-php/commit/4b3e3c9a6bbe50631aa4d5b828b9ab8dd757f08b
Raw diff: 
https://github.com/php/web-php/commit/4b3e3c9a6bbe50631aa4d5b828b9ab8dd757f08b.diff

Enhancement: Enable `whitespace_after_comma_in_array` fixer

Closes GH-637.

Changed paths:
  M  .php-cs-fixer.php
  M  cached.php
  M  manual/change.php
  M  submit-event.php


Diff:

diff --git a/.php-cs-fixer.php b/.php-cs-fixer.php
index 50c3e1ae4..fd19fe182 100644
--- a/.php-cs-fixer.php
+++ b/.php-cs-fixer.php
@@ -11,6 +11,7 @@
 
 $config->setRules([
     'no_trailing_whitespace' => true,
+    'whitespace_after_comma_in_array' => true,
 ]);
 
 return $config;
diff --git a/cached.php b/cached.php
index e155a44cb..cc0b9270a 100644
--- a/cached.php
+++ b/cached.php
@@ -22,7 +22,7 @@
 $abs = realpath($abs);
 
 if (strncmp($abs, $pwd, strlen($pwd)) != 0) {
-    header("Location: https://www.php.net/"; . 
strtr($_GET["f"],array("\r"=>"","\n"=>"")));
+    header("Location: https://www.php.net/"; . strtr($_GET["f"],array("\r"=>"", 
"\n"=>"")));
     exit;
 }
 
diff --git a/manual/change.php b/manual/change.php
index 5ce3e6700..2e480859f 100644
--- a/manual/change.php
+++ b/manual/change.php
@@ -2,7 +2,7 @@
 include_once __DIR__ . '/../include/prepend.inc';
 
 $page = isset($_GET['page']) ? htmlspecialchars($_GET['page'], ENT_QUOTES, 
'UTF-8') : '';
-$page = strtr($page, array("\r"=>"","\n"=>""));
+$page = strtr($page, array("\r"=>"", "\n"=>""));
 
 // Redirect to new manual page
 mirror_redirect("/manual/" . $page);
diff --git a/submit-event.php b/submit-event.php
index 98892a77b..18d1f5630 100644
--- a/submit-event.php
+++ b/submit-event.php
@@ -60,7 +60,7 @@
         $errors[] = "This does not look like a 'PHP' event";
     }
 
-    $valid_schemes = array('http','https','ftp');
+    $valid_schemes = array('http', 'https', 'ftp');
 
     $_POST['url'] = trim($_POST['url']);
     $pu = parse_url($_POST['url']);

-- 
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to