Skip to content

Commit

Permalink
v3.5 auto-build from v4
Browse files Browse the repository at this point in the history
  • Loading branch information
lucatume committed Feb 18, 2024
1 parent 45f35b8 commit b90b286
Show file tree
Hide file tree
Showing 27 changed files with 2,761 additions and 6 deletions.
16 changes: 16 additions & 0 deletions includes/cli-server/router.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
}
];

<<<<<<< Updated upstream
if (file_exists($root . $path)) {
// Enforces trailing slash, keeping links tidy in the admin
if (is_dir($root . $path) && substr_compare($path, '/', -strlen('/')) !== 0) {
Expand All @@ -36,6 +37,21 @@
} else {
return false;
}
=======
// Enforces trailing slash, keeping links tidy in the admin
if ( is_dir( $root.$path ) && substr_compare($path, '/', -strlen('/')) !== 0 ) {
header( "Location: $path/" );
exit;
}

// Runs PHP file if it exists
if ( strpos($path, '.php') !== false ) {
chdir( dirname( $root.$path ) );
require_once $root.$path;
} else {
return false;
}
>>>>>>> Stashed changes
} else {
// Otherwise, run `index.php`
chdir($root);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1694,7 +1694,11 @@ private function preprocess_like_expr( &$token ) {
/* Remove the quotes around the name. */
$unescaped_value = mb_substr( $token->token, 1, -1, 'UTF-8' );
if ( strpos($unescaped_value, '\_') !== false || strpos($unescaped_value, '\%') !== false ) {
<<<<<<< Updated upstream
$this->like_escape_count ++;
=======
++$this->like_escape_count;
>>>>>>> Stashed changes
return str_replace(
array( '\_', '\%' ),
array( self::LIKE_ESCAPE_CHAR . '_', self::LIKE_ESCAPE_CHAR . '%' ),
Expand Down
19 changes: 19 additions & 0 deletions src/Adapters/Symfony/Component/Process/Process.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,13 @@
class Process extends SymfonyProcess
{
/**
<<<<<<< Updated upstream
=======
* @var bool|null
*/
private static $inheritEnvironmentVariables;
/**
>>>>>>> Stashed changes
* @var bool
*/
private $createNewConsole = false;
Expand All @@ -27,8 +34,20 @@ public function __construct(
?float $timeout = 60,
array $options = null
) {
<<<<<<< Updated upstream
if (method_exists($this, 'inheritEnvironmentVariables')) {
parent::__construct($command, $cwd, $env, $input, $timeout, $options); //@phpstan-ignore-line
=======
parent::__construct($command, $cwd, $env, $input, $timeout, $options); //@phpstan-ignore-line

if (self::$inheritEnvironmentVariables === null) {
self::$inheritEnvironmentVariables = method_exists($this, 'inheritEnvironmentVariables')
&& strpos((string)(new ReflectionMethod($this, 'inheritEnvironmentVariables'))->getDocComment(), '@deprecated') === false;
}

if (self::$inheritEnvironmentVariables) {
// @phpstan-ignore-next-line
>>>>>>> Stashed changes
$this->inheritEnvironmentVariables(true);
}

Expand Down
Loading

0 comments on commit b90b286

Please sign in to comment.