1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-12 17:44:07 +02:00

Use private visibility on methods

This commit is contained in:
Jakub Vrana
2025-03-11 07:56:28 +01:00
parent c454ea8430
commit 0c15a9f42d
8 changed files with 103 additions and 103 deletions

View File

@@ -10,7 +10,7 @@ class AdminerPrettyJsonColumn {
$this->adminer = $adminer;
}
private function _testJson($value) {
private function testJson($value) {
if ((substr($value, 0, 1) == '{' || substr($value, 0, 1) == '[') && ($json = json_decode($value, true))) {
return $json;
}
@@ -18,7 +18,7 @@ class AdminerPrettyJsonColumn {
}
function editInput($table, $field, $attrs, $value) {
$json = $this->_testJson($value);
$json = $this->testJson($value);
if ($json !== $value) {
$jsonText = json_encode($json, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES);
return <<<HTML
@@ -30,7 +30,7 @@ HTML;
function processInput($field, $value, $function = '') {
if ($function === '') {
$json = $this->_testJson($value);
$json = $this->testJson($value);
if ($json !== $value) {
$value = json_encode($json);
}