Skip to content

[5.1] replace app property in SEF plugin#42926

Closed
heelc29 wants to merge 1 commit intojoomla:5.1-devfrom
heelc29:5.1/followup-42702
Closed

[5.1] replace app property in SEF plugin#42926
heelc29 wants to merge 1 commit intojoomla:5.1-devfrom
heelc29:5.1/followup-42702

Conversation

@heelc29
Copy link
Contributor

@heelc29 heelc29 commented Feb 29, 2024

Followup Pull Request for PRs #42702 and #42704 . @Hackwar

Summary of Changes

replace extra app property and replace with injected application due service provider

Testing Instructions

check new options (#42702 and #42704) are still working as expected

Actual result BEFORE applying this Pull Request

app property in plugins are deprecated

if (property_exists($this, 'app')) {
@trigger_error('The application should be injected through setApplication() and requested through getApplication().', E_USER_DEPRECATED);
$reflection = new \ReflectionClass($this);
$appProperty = $reflection->getProperty('app');
if ($appProperty->isPrivate() === false && \is_null($this->app)) {
$this->app = Factory::getApplication();
}
}

Expected result AFTER applying this Pull Request

no deprecated app property is used in sef plugin

Link to documentations

Please select:

  • No documentation changes for docs.joomla.org needed
  • No documentation changes for manual.joomla.org needed

@Quy
Copy link
Contributor

Quy commented Mar 1, 2024

#42932 includes these fixes.

@heelc29 heelc29 closed this Mar 4, 2024
@heelc29 heelc29 deleted the 5.1/followup-42702 branch March 4, 2024 15:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants