More informative error message

This commit is contained in:
Rich Morgan 2015-01-08 16:19:41 -05:00
parent 667357b039
commit e9f4c9fe2f
1 changed files with 3 additions and 1 deletions

View File

@ -21,12 +21,14 @@ class Bitpay_Core_IndexController extends Mage_Core_Controller_Front_Action
\Mage::helper('bitpay')->registerAutoloader();
\Mage::helper('bitpay')->debugData($params);
} else {
\Mage::helper('bitpay')->debugData('[ERROR] Could not get params from request.');
\Mage::helper('bitpay')->debugData('[ERROR] In Bitpay_Core_IndexController::indexAction(), Could not get parameters from HTTP request.');
}
$this->loadLayout();
$this->getResponse()->setHeader('Content-type', 'application/json');
// ?
$this->getResponse()->setBody(json_encode(array('paid' => $paid)));
}
}