Skip to content

Commit 94beb12

Browse files
authored
Merge branch '5.4-dev' into tiny-upload-default
2 parents c51c464 + 92b4591 commit 94beb12

File tree

188 files changed

+198
-471
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

188 files changed

+198
-471
lines changed

administrator/components/com_finder/src/Indexer/Adapter.php

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,15 +131,21 @@ abstract class Adapter extends CMSPlugin
131131
/**
132132
* Method to instantiate the indexer adapter.
133133
*
134-
* @param DispatcherInterface $dispatcher The object to observe.
135134
* @param array $config An array that holds the plugin configuration.
136135
*
137136
* @since 2.5
138137
*/
139-
public function __construct(DispatcherInterface $dispatcher, array $config)
138+
public function __construct($config)
140139
{
141140
// Call the parent constructor.
142-
parent::__construct($dispatcher, $config);
141+
if ($config instanceof DispatcherInterface) {
142+
$dispatcher = $config;
143+
$config = \func_num_args() > 1 ? func_get_arg(1) : [];
144+
145+
parent::__construct($dispatcher, $config);
146+
} else {
147+
parent::__construct($config);
148+
}
143149

144150
// Get the type id.
145151
$this->type_id = $this->getTypeId();

administrator/components/com_finder/src/Indexer/Query.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -733,8 +733,10 @@ protected function processDates($date1, $date2, $when1, $when2)
733733
*/
734734
protected function processString($input, $lang, $mode)
735735
{
736-
if ($input === null) {
737-
$input = '';
736+
$input = trim($input ?? '');
737+
738+
if ($input === '') {
739+
return true;
738740
}
739741

740742
// Clean up the input string.

administrator/components/com_finder/src/Indexer/Taxonomy.php

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -306,23 +306,29 @@ public static function addMap($linkId, $nodeId)
306306
*/
307307
public static function getBranchTitles()
308308
{
309-
$db = Factory::getDbo();
309+
static $titles;
310310

311-
// Set user variables
312-
$groups = implode(',', Factory::getUser()->getAuthorisedViewLevels());
311+
if ($titles === null) {
312+
$db = Factory::getDbo();
313313

314-
// Create a query to get the taxonomy branch titles.
315-
$query = $db->getQuery(true)
316-
->select($db->quoteName('title'))
317-
->from($db->quoteName('#__finder_taxonomy'))
318-
->where($db->quoteName('parent_id') . ' = 1')
319-
->where($db->quoteName('state') . ' = 1')
320-
->where($db->quoteName('access') . ' IN (' . $groups . ')');
314+
// Set user variables
315+
$groups = implode(',', Factory::getUser()->getAuthorisedViewLevels());
321316

322-
// Get the branch titles.
323-
$db->setQuery($query);
317+
// Create a query to get the taxonomy branch titles.
318+
$query = $db->getQuery(true)
319+
->select($db->quoteName('title'))
320+
->from($db->quoteName('#__finder_taxonomy'))
321+
->where($db->quoteName('parent_id') . ' = 1')
322+
->where($db->quoteName('state') . ' = 1')
323+
->where($db->quoteName('access') . ' IN (' . $groups . ')');
324+
325+
// Get the branch titles.
326+
$db->setQuery($query);
327+
328+
$titles = $db->loadColumn();
329+
}
324330

325-
return $db->loadColumn();
331+
return $titles;
326332
}
327333

328334
/**

administrator/language/en-GB/plg_editors_tinymce.ini

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
PLG_EDITORS_TINYMCE="Editor - TinyMCE"
77
PLG_TINY_BUILDER="TinyMCE Configuration Builder"
88
PLG_TINY_BUTTON_TOGGLE_EDITOR="Toggle Editor"
9-
PLG_TINY_CONFIG_TEXTFILTER_ACL_LABEL="Use Joomla Text Filter"
9+
PLG_TINY_CONFIG_TEXTFILTER_ACL_DESC="If on, the text filter from the Joomla Global Configuration is applied. If off, the filters as defined here are used."
10+
PLG_TINY_CONFIG_TEXTFILTER_ACL_LABEL="Joomla Text Filter"
1011
PLG_TINY_CORE_BUTTONS="CMS Content"
1112
PLG_TINY_DND_ADDITIONALDATA="Additional Data"
1213
PLG_TINY_DND_ALTTEXT="Image Description (Alt Text)"

phpstan-baseline.neon

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17387,6 +17387,16 @@ parameters:
1738717387
count: 2
1738817388
path: plugins/content/confirmconsent/src/Field/ConsentBoxField.php
1738917389

17390+
-
17391+
message: '''
17392+
#^Call to deprecated method setDispatcher\(\) of class Joomla\\Plugin\\Content\\Finder\\Extension\\Finder\:
17393+
5\.2 will be removed in 7\.0
17394+
Plugin should implement DispatcherAwareInterface on its own, when it is needed\.$#
17395+
'''
17396+
identifier: method.deprecated
17397+
count: 1
17398+
path: plugins/content/finder/services/provider.php
17399+
1739017400
-
1739117401
message: '''
1739217402
#^Call to deprecated method getDispatcher\(\) of class Joomla\\Plugin\\Content\\Finder\\Extension\\Finder\:
@@ -17490,6 +17500,16 @@ parameters:
1749017500
count: 2
1749117501
path: plugins/editors/codemirror/layouts/editors/codemirror/codemirror.php
1749217502

17503+
-
17504+
message: '''
17505+
#^Call to deprecated method setDispatcher\(\) of class Joomla\\Plugin\\Editors\\CodeMirror\\Extension\\Codemirror\:
17506+
5\.2 will be removed in 7\.0
17507+
Plugin should implement DispatcherAwareInterface on its own, when it is needed\.$#
17508+
'''
17509+
identifier: method.deprecated
17510+
count: 1
17511+
path: plugins/editors/codemirror/services/provider.php
17512+
1749317513
-
1749417514
message: '''
1749517515
#^Call to deprecated method getDispatcher\(\) of class Joomla\\Plugin\\Editors\\CodeMirror\\Extension\\Codemirror\:
@@ -17500,6 +17520,16 @@ parameters:
1750017520
count: 1
1750117521
path: plugins/editors/codemirror/src/Extension/Codemirror.php
1750217522

17523+
-
17524+
message: '''
17525+
#^Call to deprecated method setDispatcher\(\) of class Joomla\\Plugin\\Editors\\None\\Extension\\None\:
17526+
5\.2 will be removed in 7\.0
17527+
Plugin should implement DispatcherAwareInterface on its own, when it is needed\.$#
17528+
'''
17529+
identifier: method.deprecated
17530+
count: 1
17531+
path: plugins/editors/none/services/provider.php
17532+
1750317533
-
1750417534
message: '''
1750517535
#^Call to deprecated method getDispatcher\(\) of class Joomla\\Plugin\\Editors\\None\\Extension\\None\:
@@ -17510,6 +17540,16 @@ parameters:
1751017540
count: 1
1751117541
path: plugins/editors/none/src/Extension/None.php
1751217542

17543+
-
17544+
message: '''
17545+
#^Call to deprecated method setDispatcher\(\) of class Joomla\\Plugin\\Editors\\TinyMCE\\Extension\\TinyMCE\:
17546+
5\.2 will be removed in 7\.0
17547+
Plugin should implement DispatcherAwareInterface on its own, when it is needed\.$#
17548+
'''
17549+
identifier: method.deprecated
17550+
count: 1
17551+
path: plugins/editors/tinymce/services/provider.php
17552+
1751317553
-
1751417554
message: '''
1751517555
#^Call to deprecated method getDispatcher\(\) of class Joomla\\Plugin\\Editors\\TinyMCE\\Extension\\TinyMCE\:
@@ -17723,6 +17763,16 @@ parameters:
1772317763
count: 2
1772417764
path: plugins/system/actionlogs/src/Extension/ActionLogs.php
1772517765

17766+
-
17767+
message: '''
17768+
#^Call to deprecated method setDispatcher\(\) of class Joomla\\Plugin\\System\\Cache\\Extension\\Cache\:
17769+
5\.2 will be removed in 7\.0
17770+
Plugin should implement DispatcherAwareInterface on its own, when it is needed\.$#
17771+
'''
17772+
identifier: method.deprecated
17773+
count: 1
17774+
path: plugins/system/cache/services/provider.php
17775+
1772617776
-
1772717777
message: '''
1772817778
#^Call to deprecated method getDispatcher\(\) of class Joomla\\Plugin\\System\\Cache\\Extension\\Cache\:
@@ -17926,6 +17976,16 @@ parameters:
1792617976
count: 1
1792717977
path: plugins/system/languagefilter/src/Extension/LanguageFilter.php
1792817978

17979+
-
17980+
message: '''
17981+
#^Call to deprecated method setDispatcher\(\) of class Joomla\\Plugin\\System\\Schemaorg\\Extension\\Schemaorg\:
17982+
5\.2 will be removed in 7\.0
17983+
Plugin should implement DispatcherAwareInterface on its own, when it is needed\.$#
17984+
'''
17985+
identifier: method.deprecated
17986+
count: 1
17987+
path: plugins/system/schemaorg/services/provider.php
17988+
1792917989
-
1793017990
message: '''
1793117991
#^Call to deprecated method getDispatcher\(\) of class Joomla\\Plugin\\System\\Schemaorg\\Extension\\Schemaorg\:
@@ -17936,6 +17996,16 @@ parameters:
1793617996
count: 4
1793717997
path: plugins/system/schemaorg/src/Extension/Schemaorg.php
1793817998

17999+
-
18000+
message: '''
18001+
#^Call to deprecated method setDispatcher\(\) of class Joomla\\Plugin\\System\\Shortcut\\Extension\\Shortcut\:
18002+
5\.2 will be removed in 7\.0
18003+
Plugin should implement DispatcherAwareInterface on its own, when it is needed\.$#
18004+
'''
18005+
identifier: method.deprecated
18006+
count: 1
18007+
path: plugins/system/shortcut/services/provider.php
18008+
1793918009
-
1794018010
message: '''
1794118011
#^Call to deprecated method getDispatcher\(\) of class Joomla\\Plugin\\System\\Shortcut\\Extension\\Shortcut\:

plugins/actionlog/joomla/services/provider.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
use Joomla\Database\DatabaseInterface;
1818
use Joomla\DI\Container;
1919
use Joomla\DI\ServiceProviderInterface;
20-
use Joomla\Event\DispatcherInterface;
2120
use Joomla\Plugin\Actionlog\Joomla\Extension\Joomla;
2221

2322
return new class () implements ServiceProviderInterface {
@@ -36,7 +35,6 @@ public function register(Container $container)
3635
PluginInterface::class,
3736
function (Container $container) {
3837
$plugin = new Joomla(
39-
$container->get(DispatcherInterface::class),
4038
(array) PluginHelper::getPlugin('actionlog', 'joomla')
4139
);
4240
$plugin->setApplication(Factory::getApplication());

plugins/actionlog/joomla/src/Extension/Joomla.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424
use Joomla\Component\Actionlogs\Administrator\Plugin\ActionLogPlugin;
2525
use Joomla\Database\DatabaseAwareTrait;
2626
use Joomla\Database\Exception\ExecutionFailureException;
27-
use Joomla\Event\DispatcherInterface;
2827
use Joomla\Event\Event;
2928
use Joomla\Event\SubscriberInterface;
3029
use Joomla\Utilities\ArrayHelper;
@@ -78,14 +77,13 @@ final class Joomla extends ActionLogPlugin implements SubscriberInterface
7877
/**
7978
* Constructor.
8079
*
81-
* @param DispatcherInterface $dispatcher The dispatcher
8280
* @param array $config An optional associative array of configuration settings
8381
*
8482
* @since 3.9.0
8583
*/
86-
public function __construct(DispatcherInterface $dispatcher, array $config)
84+
public function __construct(array $config)
8785
{
88-
parent::__construct($dispatcher, $config);
86+
parent::__construct($config);
8987

9088
$params = ComponentHelper::getComponent('com_actionlogs')->getParams();
9189

plugins/api-authentication/basic/services/provider.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
use Joomla\Database\DatabaseInterface;
1818
use Joomla\DI\Container;
1919
use Joomla\DI\ServiceProviderInterface;
20-
use Joomla\Event\DispatcherInterface;
2120
use Joomla\Plugin\ApiAuthentication\Basic\Extension\Basic;
2221

2322
return new class () implements ServiceProviderInterface {
@@ -36,7 +35,6 @@ public function register(Container $container)
3635
PluginInterface::class,
3736
function (Container $container) {
3837
$plugin = new Basic(
39-
$container->get(DispatcherInterface::class),
4038
(array) PluginHelper::getPlugin('api-authentication', 'basic'),
4139
);
4240
$plugin->setApplication(Factory::getApplication());

plugins/api-authentication/token/services/provider.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
use Joomla\Database\DatabaseInterface;
1818
use Joomla\DI\Container;
1919
use Joomla\DI\ServiceProviderInterface;
20-
use Joomla\Event\DispatcherInterface;
2120
use Joomla\Filter\InputFilter;
2221
use Joomla\Plugin\ApiAuthentication\Token\Extension\Token;
2322

@@ -37,7 +36,6 @@ public function register(Container $container)
3736
PluginInterface::class,
3837
function (Container $container) {
3938
$plugin = new Token(
40-
$container->get(DispatcherInterface::class),
4139
(array) PluginHelper::getPlugin('api-authentication', 'token'),
4240
new InputFilter()
4341
);

plugins/api-authentication/token/src/Extension/Token.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
use Joomla\CMS\User\UserFactoryAwareTrait;
1818
use Joomla\Database\DatabaseAwareTrait;
1919
use Joomla\Database\ParameterType;
20-
use Joomla\Event\DispatcherInterface;
2120
use Joomla\Event\SubscriberInterface;
2221
use Joomla\Filter\InputFilter;
2322

@@ -74,15 +73,14 @@ public static function getSubscribedEvents(): array
7473
/**
7574
* Constructor.
7675
*
77-
* @param DispatcherInterface $dispatcher The dispatcher
7876
* @param array $config An optional associative array of configuration settings
7977
* @param InputFilter $filter The input filter
8078
*
8179
* @since 4.2.0
8280
*/
83-
public function __construct(DispatcherInterface $dispatcher, array $config, InputFilter $filter)
81+
public function __construct(array $config, InputFilter $filter)
8482
{
85-
parent::__construct($dispatcher, $config);
83+
parent::__construct($config);
8684

8785
$this->filter = $filter;
8886
}

0 commit comments

Comments
 (0)