Skip to content

Commit b35d4f4

Browse files
authored
Merge branch '6.0-dev' into toolbar
2 parents 260973f + 2b523f1 commit b35d4f4

File tree

8 files changed

+31
-14
lines changed

8 files changed

+31
-14
lines changed

.github/CONTRIBUTING.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,10 @@ Please be patient as not all items will be viewed or tested immediately (remembe
2020
Bug fixing PRs should be made to the `5.4-dev` branch. Merged bugfixes will be upmerged into the current branches. New features that do not break backwards compatibility should be made to the `6.1-dev`.
2121

2222

23-
| Branch | Purpose |
24-
|---------|-----------------------------------------------------------------------------------------|
25-
| 5.4-dev | Branch for the current 5.x Joomla version. |
26-
| 6.0-dev | Branch for the current 6.x Joomla version. Bugfixes only for 6.x go into this branch. |
27-
| 6.1-dev | Branch for the next minor 6.x Joomla version. New features have to go into this branch. |
23+
| Branch | Purpose |
24+
|---------|--------------------------------------------------------------------------------------------------------------|
25+
| 5.4-dev | Branch for the current 5.x Joomla version. |
26+
| 6.0-dev | Branch for the current 6.x Joomla version. Bugfixes only for 6.0 go into this branch. |
27+
| 6.1-dev | Branch for the next minor 6.x Joomla version. Bugfixes only for 6.1 go into this branch. |
28+
| 6.2-dev | Branch for the next minor 6.x Joomla version. New features have to go into this branch. |
29+
| 7.0-dev | Branch for the next major Joomla version. New features that include a b/c break have to go into this branch. |

.github/workflows/merge-conflicts.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: "Detect merge conflicts"
22
on:
33
# So that PRs touching the same files as the push are updated
44
push:
5-
# So that the `dirtyLabel` is removed if conflicts are resolve
5+
# So that the `dirtyLabel` is removed if conflicts are resolved
66
# We recommend `pull_request_target` so that github secrets are available.
77
# In `pull_request` we wouldn't be able to change labels of fork PRs
88
pull_request_target:

administrator/components/com_scheduler/src/Model/TaskModel.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -418,11 +418,17 @@ public function getTask(array $options = []): ?\stdClass
418418
*/
419419
private function hasRunningTasks($db): bool
420420
{
421+
$now = Factory::getDate('now', 'UTC');
422+
$timeout = ComponentHelper::getParams('com_scheduler')->get('timeout', 300);
423+
$threshold = (clone $now)->modify("-$timeout seconds")->toSql();
424+
421425
$lockCountQuery = $db->createQuery()
422426
->select('COUNT(id)')
423427
->from($db->quoteName(self::TASK_TABLE))
424428
->where($db->quoteName('locked') . ' IS NOT NULL')
425-
->where($db->quoteName('state') . ' = 1');
429+
->where($db->quoteName('locked') . ' > :threshold')
430+
->where($db->quoteName('state') . ' = 1')
431+
->bind(':threshold', $threshold);
426432

427433
try {
428434
$runningCount = $db->setQuery($lockCountQuery)->loadResult();

administrator/components/com_scheduler/src/Model/TasksModel.php

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -484,14 +484,23 @@ public function hasDueTasks(Date $time): bool
484484
$db = $this->getDatabase();
485485
$now = $time->toSql();
486486

487+
$timeout = ComponentHelper::getParams('com_scheduler')->get('timeout', 300);
488+
$threshold = (clone $time)->modify("-$timeout seconds")->toSql();
489+
487490
$query = $db->createQuery()
488491
// Count due tasks
489492
->select('SUM(CASE WHEN ' . $db->quoteName('a.next_execution') . ' <= :now THEN 1 ELSE 0 END) AS due_count')
490493
// Count locked tasks
491-
->select('SUM(CASE WHEN ' . $db->quoteName('a.locked') . ' IS NULL THEN 0 ELSE 1 END) AS locked_count')
494+
->select(
495+
'SUM(CASE WHEN ' .
496+
$db->quoteName('a.locked') . ' IS NOT NULL AND ' .
497+
$db->quoteName('a.locked') . ' > :threshold ' .
498+
'THEN 1 ELSE 0 END) AS locked_count'
499+
)
492500
->from($db->quoteName('#__scheduler_tasks', 'a'))
493501
->where($db->quoteName('a.state') . ' = 1')
494-
->bind(':now', $now);
502+
->bind(':now', $now)
503+
->bind(':threshold', $threshold);
495504

496505
$db->setQuery($query);
497506

build/media_source/templates/administrator/atum/scss/vendor/choicesjs/choices.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@
8585
background-color: var(--body-bg);
8686

8787
.choices__item {
88-
padding-inline-end: 10px;
88+
padding-inline-end: 25px;
8989
}
9090

9191
.choices__item--selectable {

libraries/src/HTML/HTMLHelper.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ final public static function _(string $key, ...$methodArgs)
211211
public static function register($key, callable $function)
212212
{
213213
@trigger_error(
214-
'Support for registering functions is deprecated and will be removed in Joomla 6.0, use the service registry instead',
214+
'Support for registering functions is deprecated and will be removed in Joomla 7.0, use the service registry instead',
215215
E_USER_DEPRECATED
216216
);
217217

@@ -236,7 +236,7 @@ public static function register($key, callable $function)
236236
public static function unregister($key)
237237
{
238238
@trigger_error(
239-
'Support for registering functions is deprecated and will be removed in Joomla 6.0, use the service registry instead',
239+
'Support for registering functions is deprecated and will be removed in Joomla 7.0, use the service registry instead',
240240
E_USER_DEPRECATED
241241
);
242242

modules/mod_articles/tmpl/default_items.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@
108108

109109
<?php echo $item->event->afterDisplayContent; ?>
110110

111-
<?php if ($params->get('show_readmore')) : ?>
111+
<?php if ($params->get('show_readmore') && !empty($item->fulltext)) : ?>
112112
<?php if ($params->get('show_readmore_title', '') !== '') : ?>
113113
<?php $item->params->set('show_readmore_title', $params->get('show_readmore_title')); ?>
114114
<?php $item->params->set('readmore_limit', $params->get('readmore_limit')); ?>

modules/mod_tags_popular/src/Helper/TagsPopularHelper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public function getTags(&$params)
5555
->select(
5656
[
5757
'MAX(' . $db->quoteName('tag_id') . ') AS ' . $db->quoteName('tag_id'),
58-
'COUNT(*) AS ' . $db->quoteName('count'),
58+
'COUNT(DISTINCT ' . $db->quoteName('m.core_content_id') . ') AS ' . $db->quoteName('count'),
5959
'MAX(' . $db->quoteName('t.title') . ') AS ' . $db->quoteName('title'),
6060
'MAX(' . $db->quoteName('t.access') . ') AS ' . $db->quoteName('access'),
6161
'MAX(' . $db->quoteName('t.alias') . ') AS ' . $db->quoteName('alias'),

0 commit comments

Comments
 (0)