Skip to content

Commit

Permalink
Merge remote-tracking branch 'security/security/279' into QA_4_9
Browse files Browse the repository at this point in the history
  • Loading branch information
ibennetch committed Sep 20, 2019
2 parents 988e644 + 6e1bbc5 commit 0de99c8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 14 deletions.
Expand Up @@ -86,7 +86,7 @@ public function indexAction()
$scripts->addFile('server_databases.js');

$this->_setSortDetails();
$this->_dbstats = empty($_REQUEST['dbstats']) ? false : true;
$this->_dbstats = ! empty($_POST['dbstats']);
$this->_pos = empty($_REQUEST['pos']) ? 0 : (int) $_REQUEST['pos'];

/**
Expand Down
20 changes: 7 additions & 13 deletions templates/server/databases/databases_footer.twig
Expand Up @@ -63,19 +63,13 @@
{# Enable statistics #}
{% if dbstats is empty %}
{{ Message_notice('Note: Enabling the database statistics here might cause heavy traffic between the web server and the MySQL server.'|trans) }}

{% set content %}
<strong>{% trans 'Enable statistics' %}</strong>
{% endset %}
{% set items = [{
'content': content,
'class': 'li_switch_dbstats',
'url': {
'href': 'server_databases.php' ~ Url_getCommon({'dbstats': '1'}),
'title': 'Enable statistics'|trans
}
}] %}
{% include 'list/unordered.twig' with {'items': items} only %}
<ul>
<li class="li_switch_dbstats">
<a href="server_databases.php" data-post="{{ Url_getCommon({'dbstats': '1'}, '') }}" title="{% trans 'Enable statistics' %}">
<strong>{% trans 'Enable statistics' %}</strong>
</a>
</li>
</ul>
{% endif %}
</form>
</div>

0 comments on commit 0de99c8

Please sign in to comment.