Skip to content

Commit 7cc7b25

Browse files
authored
[5.1] Merge pull request #43172 from LadySolveig/5.1/upmerges/2024-03-28
2 parents d0ba16f + cd22b4d commit 7cc7b25

File tree

3 files changed

+16
-9
lines changed

3 files changed

+16
-9
lines changed

components/com_users/src/View/Profile/HtmlView.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -139,13 +139,14 @@ public function display($tpl = null)
139139
unset($this->data->text);
140140

141141
// Check for layout from menu item.
142-
$query = Factory::getApplication()->getMenu()->getActive()->query;
142+
$active = Factory::getApplication()->getMenu()->getActive();
143143

144144
if (
145-
isset($query['layout']) && isset($query['option']) && $query['option'] === 'com_users'
146-
&& isset($query['view']) && $query['view'] === 'profile'
145+
$active && isset($active->query['layout'])
146+
&& isset($active->query['option']) && $active->query['option'] === 'com_users'
147+
&& isset($active->query['view']) && $active->query['view'] === 'profile'
147148
) {
148-
$this->setLayout($query['layout']);
149+
$this->setLayout($active->query['layout']);
149150
}
150151

151152
// Escape strings for HTML output

htaccess.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ Options -Indexes
136136
</IfModule>
137137
</IfModule>
138138

139-
## GZIP
139+
## GZIP & BROTLI
140140
## These directives are only enabled if the Apache mod_headers module is enabled.
141141
## This section will check if a .gz file exists and if so will stream it
142142
## directly or fallback to gzip any asset on the fly
@@ -157,9 +157,9 @@ Options -Indexes
157157
RewriteCond "%{REQUEST_FILENAME}\.gz" -s
158158
RewriteRule "^(.*)\.js" "$1\.js\.gz" [QSA]
159159

160-
# Serve correct content types, and prevent mod_deflate double gzip.
161-
RewriteRule "\.css\.gz$" "-" [T=text/css,E=no-gzip:1]
162-
RewriteRule "\.js\.gz$" "-" [T=text/javascript,E=no-gzip:1]
160+
# Serve correct content types, and prevent mod_deflate double compression.
161+
RewriteRule "\.css\.gz$" "-" [T=text/css,E=no-gzip:1,E=no-brotli:1]
162+
RewriteRule "\.js\.gz$" "-" [T=text/javascript,E=no-gzip:1,E=no-brotli:1]
163163

164164
<FilesMatch "(\.js\.gz|\.css\.gz)$">
165165
# Serve correct encoding type.

libraries/src/MVC/View/ListView.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,13 @@ protected function addToolbar()
251251
$bar->appendButton('Custom', $dhtml, 'batch');
252252
}
253253

254-
if ($this->state->get('filter.published') == -2 && $canDo->get('core.delete')) {
254+
if (
255+
$canDo->get('core.delete') &&
256+
(
257+
$this->state->get('filter.state') == -2 ||
258+
$this->state->get('filter.published') == -2
259+
)
260+
) {
255261
ToolbarHelper::deleteList('JGLOBAL_CONFIRM_DELETE', $viewName . '.delete', 'JTOOLBAR_EMPTY_TRASH');
256262
} elseif ($canDo->get('core.edit.state')) {
257263
ToolbarHelper::trash($viewName . '.trash');

0 commit comments

Comments
 (0)