Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix check and assignment of orderId #26

Merged
merged 2 commits into from
May 10, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@ class KwcShop_Kwc_Shop_Cart_Checkout_Payment_Qenta_Cancel_ContentSender extends
public function sendContent($includeMaster)
{
$session = new Kwf_Session_Namespace('kwcShopCart');
if (!$orderId = $session->qentaCartId && isset($_POST['babytuch_orderId'])) {
if ($session->qentaCartId) {
$orderId = $session->qentaCartId;
} else if (isset($_POST['babytuch_orderId'])) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is there babytuch in the variable name ;)?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed it now

$orderId = $_POST['babytuch_orderId'];
}
if ($orderId) {

if (isset($orderId)) {
KwcShop_Kwc_Shop_Cart_Orders::setCartOrderId($orderId);
$order = Kwf_Model_Abstract::getInstance(Kwc_Abstract::getSetting($this->_data->parent->parent->parent->componentClass, 'childModel'))
->getReferencedModel('Order')->getCartOrder();
Expand Down