sslcommerz / SSLCommerz-Laravel

SSLCOMMERZ is a bangladeshi payment gateway provider. This is Laravel Library for SSLCOMMERZ.
123 stars 98 forks source link

Cannot use isset() on the result of an expression (you can use "null !== expression" instead) #12

Closed devdict closed 4 years ago

devdict commented 4 years ago

I found this error

Cannot use isset() on the result of an expression (you can use "null !== expression" instead)

in app/Library/SslCommerz/AbstractSslCommerz.php:97

 if(isset($this->getApiUrl()) && $this->getApiUrl() == 'https://securepay.sslcommerz.com') {
                   $response = json_encode(['status' => 'SUCCESS', 'data' => $sslcz['GatewayPageURL'], 'logo' => $sslcz['storeLogo']]);
                } else {
                    $response = json_encode(['status' => 'success', 'data' => $sslcz['GatewayPageURL'], 'logo' => $sslcz['storeLogo']]);
                }

If replace this by $response = json_encode(['status' => 'SUCCESS', 'data' => $sslcz['GatewayPageURL'], 'logo' => $sslcz['storeLogo']]);

It work

rkbi commented 4 years ago

bug fixed with #13