Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace string interpolation deprectaed in PHP 8.2 #38983

Merged
merged 2 commits into from
Nov 9, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ protected function getLayoutPaths(): array
$s = DIRECTORY_SEPARATOR;

return array_merge(
[JPATH_ADMINISTRATOR . "${s}/components${s}com_scheduler${s}layouts${s}"],
[JPATH_ADMINISTRATOR . "{$s}/components{$s}com_scheduler{$s}layouts{$s}"],
parent::getLayoutPaths()
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ class TaskOption
public function __construct(string $type, string $langConstPrefix)
{
$this->id = $type;
$this->title = Text::_("${langConstPrefix}_TITLE");
$this->desc = Text::_("${langConstPrefix}_DESC");
$this->title = Text::_("{$langConstPrefix}_TITLE");
$this->desc = Text::_("{$langConstPrefix}_DESC");
$this->langConstPrefix = $langConstPrefix;
}

Expand Down
8 changes: 4 additions & 4 deletions libraries/src/Console/TasksStateCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,14 +130,14 @@ protected function doExecute(InputInterface $input, OutputInterface $output): in

// We couldn't fetch that task :(
if (empty($task->id)) {
$this->ioStyle->error("Task ID '${id}' does not exist!");
$this->ioStyle->error("Task ID '{$id}' does not exist!");

return 1;
}

// If the item is checked-out we need a check in (currently not possible through the CLI)
if ($taskModel->isCheckedOut($task)) {
$this->ioStyle->error("Task ID '${id}' is checked out!");
$this->ioStyle->error("Task ID '{$id}' is checked out!");

return 1;
}
Expand All @@ -148,12 +148,12 @@ protected function doExecute(InputInterface $input, OutputInterface $output): in
$action = Task::STATE_MAP[$state];

if (!$table->publish($id, $state)) {
$this->ioStyle->error("Can't ${action} Task ID '${id}'");
$this->ioStyle->error("Can't {$action} Task ID '{$id}'");

return 3;
}

$this->ioStyle->success("Task ID ${id} ${action}.");
$this->ioStyle->success("Task ID {$id} {$action}.");

return 0;
}
Expand Down
2 changes: 1 addition & 1 deletion libraries/src/Installer/Adapter/PluginAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ public function loadLanguage($path = null)
}

if ($name) {
$extension = "plg_${group}_${name}";
$extension = "plg_{$group}_{$name}";
$source = $path ?: JPATH_PLUGINS . "/$group/$name";
$folder = (string) $element->attributes()->folder;

Expand Down