Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMohamed Ashraf <mohamed.ashraf.213@gmail.com>2013-11-18 02:17:18 +0400
committerMohamed Ashraf <mohamed.ashraf.213@gmail.com>2013-11-18 02:17:18 +0400
commit38fea8e66325042a68ae6cea572df05a3fe40573 (patch)
treeff9952701d9b87405a265078fc79df67f31cdc71 /error_report.php
parentf82e321b753bbf5a123365c7deb474162bf45656 (diff)
Fixed linting error
Diffstat (limited to 'error_report.php')
-rw-r--r--error_report.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/error_report.php b/error_report.php
index a0566d5609..bd63b97522 100644
--- a/error_report.php
+++ b/error_report.php
@@ -14,7 +14,14 @@ if (isset($_REQUEST['send_error_report'])
&& $_REQUEST['send_error_report'] == true
) {
$server_response = PMA_sendErrorReport(PMA_getReportData(false));
- $success = $server_response === false ? false : json_decode($server_response, true)["success"];
+
+ if ($server_response === false) {
+ $success = false;
+ } else {
+ $decoded_response = json_decode($server_response, true);
+ $success = !empty($decoded_response) ? $decoded_response["success"] : false;
+ }
+
if ($_REQUEST['automatic'] === "true") {
if ($success) {
$response->addJSON(