?
avatar simongareste
simongareste
20 Apr 2018

On Joomla 3.8.7, CMSApplication function getPathway($name=null, $options = array()) logs a warning regarding $name which is deprecated.

So CMSApplication->getPathway(null,[]) will work fine, but CMSApplication->getPathway('site',[]) will not.

However, SiteApplication extends CMSApplication, and its getPathway function is

	public function getPathway($name = 'site', $options = array())
	{
		return parent::getPathway($name, $options);
	}

So this will always call CMSApplication with a $name, which will in turn print the warning.
So I'll alway get a warning when I write:

$app = JFactory::getApplication();
$pathway = $app->getPathway();

What should I do to avoid this?

Simon

avatar simongareste simongareste - open - 20 Apr 2018
avatar joomla-cms-bot joomla-cms-bot - change - 20 Apr 2018
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 20 Apr 2018
avatar franz-wohlkoenig franz-wohlkoenig - change - 20 Apr 2018
Category Code style
avatar franz-wohlkoenig franz-wohlkoenig - change - 21 Apr 2018
Status New Closed
Closed_Date 0000-00-00 00:00:00 2018-04-21 05:30:06
Closed_By franz-wohlkoenig
avatar joomla-cms-bot joomla-cms-bot - change - 21 Apr 2018
Closed_By franz-wohlkoenig joomla-cms-bot
avatar joomla-cms-bot joomla-cms-bot - close - 21 Apr 2018
avatar joomla-cms-bot
joomla-cms-bot - comment - 21 Apr 2018
avatar NickSdot
NickSdot - comment - 21 Apr 2018

@simongareste
Please test: #20206

avatar simongareste
simongareste - comment - 21 Apr 2018

Works for me. Thanks!

Simon

Le sam. 21 avr. 2018 à 08:05, NickSdot notifications@github.com a écrit :

@simongareste https://github.com/simongareste
Please test: #20206 #20206


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#20203 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AEasYhcnJjHcxoCSYHic842LSbA-NHA5ks5tqswWgaJpZM4TdCgZ
.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 21 Apr 2018

@simongareste please mark your Test as successfully:

  • open Issue Tracker
  • Login with your github-Account
  • Click on blue "Test this"-Button above Authors-Picture
  • mark your Test as successfully
  • hit "submit test result"

Add a Comment

Login with GitHub to post a comment