@@ -44,7 +44,7 @@ |
||
| 44 | 44 | |
| 45 | 45 | header('HTTP/1.1 200 Ok', true, 200); |
| 46 | 46 | header('Content-Type: application/json', true); |
| 47 | - header('Content-Length: ' . Tools::strlen($result)); |
|
| 47 | + header('Content-Length: '.Tools::strlen($result)); |
|
| 48 | 48 | |
| 49 | 49 | echo $result; |
| 50 | 50 | exit(); |
@@ -72,8 +72,8 @@ |
||
| 72 | 72 | $paylaterPublicKey = Configuration::get('pmt_public_key'); |
| 73 | 73 | $paylaterPrivateKey = Configuration::get('pmt_private_key'); |
| 74 | 74 | $okUrl = _PS_BASE_URL_.__PS_BASE_URI__ |
| 75 | - .'index.php?canonical=true&fc=module&module=paylater&controller=notify&' |
|
| 76 | - .http_build_query($query) |
|
| 75 | + .'index.php?canonical=true&fc=module&module=paylater&controller=notify&' |
|
| 76 | + .http_build_query($query) |
|
| 77 | 77 | ; |
| 78 | 78 | |
| 79 | 79 | $shippingAddress = new Address($cart->id_address_delivery); |
@@ -15,9 +15,9 @@ discard block |
||
| 15 | 15 | { |
| 16 | 16 | if (_PS_VERSION_ < 1.6) { |
| 17 | 17 | Logger::addLog( |
| 18 | - 'PagaMasTarde Exception For user ' . |
|
| 19 | - $customer->email . |
|
| 20 | - ' : ' . |
|
| 18 | + 'PagaMasTarde Exception For user '. |
|
| 19 | + $customer->email. |
|
| 20 | + ' : '. |
|
| 21 | 21 | $exception->getMessage(), |
| 22 | 22 | 3, |
| 23 | 23 | $exception->getCode(), |
@@ -27,9 +27,9 @@ discard block |
||
| 27 | 27 | ); |
| 28 | 28 | } else { |
| 29 | 29 | PrestaShopLogger::addLog( |
| 30 | - 'PagaMasTarde Exception For user ' . |
|
| 31 | - $customer->email . |
|
| 32 | - ' : ' . |
|
| 30 | + 'PagaMasTarde Exception For user '. |
|
| 31 | + $customer->email. |
|
| 32 | + ' : '. |
|
| 33 | 33 | $exception->getMessage(), |
| 34 | 34 | 3, |
| 35 | 35 | $exception->getCode(), |
@@ -88,22 +88,22 @@ discard block |
||
| 88 | 88 | ); |
| 89 | 89 | |
| 90 | 90 | try { |
| 91 | - $userAddress = new \PagaMasTarde\OrdersApiClient\Model\Order\User\Address(); |
|
| 91 | + $userAddress = new \PagaMasTarde\OrdersApiClient\Model\Order\User\Address(); |
|
| 92 | 92 | $userAddress |
| 93 | 93 | ->setZipCode($shippingAddress->postcode) |
| 94 | - ->setFullName($shippingAddress->firstname . ' ' . $shippingAddress->lastname) |
|
| 94 | + ->setFullName($shippingAddress->firstname.' '.$shippingAddress->lastname) |
|
| 95 | 95 | ->setCountryCode('ES') |
| 96 | 96 | ->setCity($shippingAddress->city) |
| 97 | - ->setAddress($shippingAddress->address1 . ' ' . $shippingAddress->address2) |
|
| 97 | + ->setAddress($shippingAddress->address1.' '.$shippingAddress->address2) |
|
| 98 | 98 | ; |
| 99 | 99 | |
| 100 | - $orderShippingAddress = new \PagaMasTarde\OrdersApiClient\Model\Order\User\Address(); |
|
| 100 | + $orderShippingAddress = new \PagaMasTarde\OrdersApiClient\Model\Order\User\Address(); |
|
| 101 | 101 | $orderShippingAddress |
| 102 | 102 | ->setZipCode($shippingAddress->postcode) |
| 103 | - ->setFullName($shippingAddress->firstname . ' ' . $shippingAddress->lastname) |
|
| 103 | + ->setFullName($shippingAddress->firstname.' '.$shippingAddress->lastname) |
|
| 104 | 104 | ->setCountryCode('ES') |
| 105 | 105 | ->setCity($shippingAddress->city) |
| 106 | - ->setAddress($shippingAddress->address1 . ' ' . $shippingAddress->address2) |
|
| 106 | + ->setAddress($shippingAddress->address1.' '.$shippingAddress->address2) |
|
| 107 | 107 | ->setDni($shippingAddress->dni) |
| 108 | 108 | ->setFixPhone($shippingAddress->phone) |
| 109 | 109 | ->setMobilePhone($shippingAddress->phone_mobile) |
@@ -112,10 +112,10 @@ discard block |
||
| 112 | 112 | $orderBillingAddress = new \PagaMasTarde\OrdersApiClient\Model\Order\User\Address(); |
| 113 | 113 | $orderBillingAddress |
| 114 | 114 | ->setZipCode($billingAddress->postcode) |
| 115 | - ->setFullName($billingAddress->firstname . ' ' . $billingAddress->lastname) |
|
| 115 | + ->setFullName($billingAddress->firstname.' '.$billingAddress->lastname) |
|
| 116 | 116 | ->setCountryCode('ES') |
| 117 | 117 | ->setCity($billingAddress->city) |
| 118 | - ->setAddress($billingAddress->address1 . ' ' . $billingAddress->address2) |
|
| 118 | + ->setAddress($billingAddress->address1.' '.$billingAddress->address2) |
|
| 119 | 119 | ->setDni($billingAddress->dni) |
| 120 | 120 | ->setFixPhone($billingAddress->phone) |
| 121 | 121 | ->setMobilePhone($billingAddress->phone_mobile) |
@@ -133,7 +133,7 @@ discard block |
||
| 133 | 133 | ->setDni($shippingAddress->dni) |
| 134 | 134 | ; |
| 135 | 135 | |
| 136 | - if ($customer->birthday!='0000-00-00') { |
|
| 136 | + if ($customer->birthday != '0000-00-00') { |
|
| 137 | 137 | $orderUser->setDateOfBirth($customer->birthday); |
| 138 | 138 | } |
| 139 | 139 | |
@@ -207,13 +207,13 @@ discard block |
||
| 207 | 207 | } catch (\Exception $exception) { |
| 208 | 208 | $this->saveLog( |
| 209 | 209 | array( |
| 210 | - 'exception' => 'Exception for user ' . $customer->email . ' : ' . $exception->getMessage() |
|
| 210 | + 'exception' => 'Exception for user '.$customer->email.' : '.$exception->getMessage() |
|
| 211 | 211 | ) |
| 212 | 212 | ); |
| 213 | 213 | Tools::redirect($cancelUrl); |
| 214 | 214 | } |
| 215 | 215 | |
| 216 | - $url =''; |
|
| 216 | + $url = ''; |
|
| 217 | 217 | try { |
| 218 | 218 | $orderClient = new \PagaMasTarde\OrdersApiClient\Client( |
| 219 | 219 | $paylaterPublicKey, |
@@ -224,7 +224,7 @@ discard block |
||
| 224 | 224 | $url = $order->getActionUrls()->getForm(); |
| 225 | 225 | $orderId = $order->getId(); |
| 226 | 226 | $result = Db::getInstance()->execute( |
| 227 | - "INSERT INTO `" . _DB_PREFIX_ . "pmt_order` (`id`, `order_id`) |
|
| 227 | + "INSERT INTO `"._DB_PREFIX_."pmt_order` (`id`, `order_id`) |
|
| 228 | 228 | VALUES ('$cart->id','$orderId') |
| 229 | 229 | ON DUPLICATE KEY UPDATE `order_id` = '$orderId'" |
| 230 | 230 | ); |
@@ -237,7 +237,7 @@ discard block |
||
| 237 | 237 | } catch (\Exception $exception) { |
| 238 | 238 | $this->saveLog( |
| 239 | 239 | array( |
| 240 | - 'exception' => 'Exception for user ' . $customer->email . ' : ' . $exception->getMessage() |
|
| 240 | + 'exception' => 'Exception for user '.$customer->email.' : '.$exception->getMessage() |
|
| 241 | 241 | ) |
| 242 | 242 | ); |
| 243 | 243 | Tools::redirect($cancelUrl); |
@@ -260,7 +260,7 @@ discard block |
||
| 260 | 260 | } catch (\Exception $exception) { |
| 261 | 261 | $this->saveLog( |
| 262 | 262 | array( |
| 263 | - 'exception' => 'Exception for user ' . $customer->email . ' : ' . $exception->getMessage() |
|
| 263 | + 'exception' => 'Exception for user '.$customer->email.' : '.$exception->getMessage() |
|
| 264 | 264 | ) |
| 265 | 265 | ); |
| 266 | 266 | Tools::redirect($url); |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | |
| 67 | 67 | header('HTTP/1.1 200 Ok', true, 200); |
| 68 | 68 | header('Content-Type: application/json', true); |
| 69 | - header('Content-Length: ' . Tools::strlen($result)); |
|
| 69 | + header('Content-Length: '.Tools::strlen($result)); |
|
| 70 | 70 | |
| 71 | 71 | echo $result; |
| 72 | 72 | exit(); |
@@ -90,7 +90,7 @@ discard block |
||
| 90 | 90 | |
| 91 | 91 | header('HTTP/1.1 403 Forbidden', true, 403); |
| 92 | 92 | header('Content-Type: application/json', true); |
| 93 | - header('Content-Length: ' . Tools::strlen($result)); |
|
| 93 | + header('Content-Length: '.Tools::strlen($result)); |
|
| 94 | 94 | |
| 95 | 95 | echo $result; |
| 96 | 96 | exit(); |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | { |
| 34 | 34 | $parsedUrl = parse_url($url); |
| 35 | 35 | $separator = ($parsedUrl['query'] == null) ? '?' : '&'; |
| 36 | - $redirectUrl = $url. $separator . http_build_query($parameters); |
|
| 36 | + $redirectUrl = $url.$separator.http_build_query($parameters); |
|
| 37 | 37 | Tools::redirect($redirectUrl); |
| 38 | 38 | } |
| 39 | 39 | |
@@ -62,7 +62,7 @@ discard block |
||
| 62 | 62 | 429 => "Too Many Requests", |
| 63 | 63 | 500 => "Internal Server Error", |
| 64 | 64 | ); |
| 65 | - return isset($httpStatusCodes)? $httpStatusCodes[$statusCode] : $httpStatusCodes[200]; |
|
| 65 | + return isset($httpStatusCodes) ? $httpStatusCodes[$statusCode] : $httpStatusCodes[200]; |
|
| 66 | 66 | } |
| 67 | 67 | |
| 68 | 68 | /** |
@@ -194,7 +194,7 @@ discard block |
||
| 194 | 194 | private function getPmtOrderId() |
| 195 | 195 | { |
| 196 | 196 | try { |
| 197 | - $this->pmtOrderId= Db::getInstance()->getValue( |
|
| 197 | + $this->pmtOrderId = Db::getInstance()->getValue( |
|
| 198 | 198 | 'select order_id from '._DB_PREFIX_.'pmt_order where id = '.$this->merchantOrderId |
| 199 | 199 | ); |
| 200 | 200 | |
@@ -256,7 +256,7 @@ discard block |
||
| 256 | 256 | public function validateAmount() |
| 257 | 257 | { |
| 258 | 258 | $totalAmount = $this->pmtOrder->getShoppingCart()->getTotalAmount(); |
| 259 | - $merchantAmount = (int)((string) (100 * $this->merchantOrder->getOrderTotal(true))); |
|
| 259 | + $merchantAmount = (int) ((string) (100 * $this->merchantOrder->getOrderTotal(true))); |
|
| 260 | 260 | if ($totalAmount != $merchantAmount) { |
| 261 | 261 | throw new AmountMismatchException($totalAmount, $merchantAmount); |
| 262 | 262 | } |
@@ -275,7 +275,7 @@ discard block |
||
| 275 | 275 | Configuration::get('PS_OS_PAYMENT'), |
| 276 | 276 | $this->merchantOrder->getOrderTotal(true), |
| 277 | 277 | $this->module->displayName, |
| 278 | - 'pmtOrderId: ' . $this->pmtOrder->getId(), |
|
| 278 | + 'pmtOrderId: '.$this->pmtOrder->getId(), |
|
| 279 | 279 | array('transaction_id' => $this->pmtOrderId), |
| 280 | 280 | null, |
| 281 | 281 | false, |
@@ -334,7 +334,7 @@ discard block |
||
| 334 | 334 | protected function unblockConcurrency() |
| 335 | 335 | { |
| 336 | 336 | try { |
| 337 | - Db::getInstance()->delete('pmt_cart_process', 'timestamp < ' . (time() - 6)); |
|
| 337 | + Db::getInstance()->delete('pmt_cart_process', 'timestamp < '.(time() - 6)); |
|
| 338 | 338 | } catch (\Exception $exception) { |
| 339 | 339 | throw new ConcurrencyException(); |
| 340 | 340 | } |
@@ -349,13 +349,13 @@ discard block |
||
| 349 | 349 | public function cancelProcess() |
| 350 | 350 | { |
| 351 | 351 | if ($this->merchantOrder) { |
| 352 | - $id = (!is_null($this->pmtOrder))?$this->pmtOrder->getId():null; |
|
| 352 | + $id = (!is_null($this->pmtOrder)) ? $this->pmtOrder->getId() : null; |
|
| 353 | 353 | $this->module->validateOrder( |
| 354 | 354 | $this->merchantOrderId, |
| 355 | 355 | Configuration::get('PS_OS_ERROR'), |
| 356 | 356 | $this->merchantOrder->getOrderTotal(true), |
| 357 | 357 | $this->module->displayName, |
| 358 | - 'pmtOrderId: ' . $id, |
|
| 358 | + 'pmtOrderId: '.$id, |
|
| 359 | 359 | null, |
| 360 | 360 | null, |
| 361 | 361 | false, |
@@ -390,9 +390,9 @@ discard block |
||
| 390 | 390 | 'id_cart' => $this->merchantOrderId, |
| 391 | 391 | 'key' => $this->config['secureKey'], |
| 392 | 392 | 'id_module' => $this->module->id, |
| 393 | - 'id_order' => ($this->pmtOrder)?$this->pmtOrder->getId(): null, |
|
| 393 | + 'id_order' => ($this->pmtOrder) ? $this->pmtOrder->getId() : null, |
|
| 394 | 394 | ); |
| 395 | - $url = ($error)? $this->config['urlKO'] : $this->config['urlOK']; |
|
| 395 | + $url = ($error) ? $this->config['urlKO'] : $this->config['urlOK']; |
|
| 396 | 396 | return $this->redirect($url, $parameters); |
| 397 | 397 | } |
| 398 | 398 | } |
@@ -11,7 +11,7 @@ discard block |
||
| 11 | 11 | exit; |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | -define('_PS_PAYLATER_DIR', _PS_MODULE_DIR_. '/paylater'); |
|
| 14 | +define('_PS_PAYLATER_DIR', _PS_MODULE_DIR_.'/paylater'); |
|
| 15 | 15 | |
| 16 | 16 | require _PS_PAYLATER_DIR.'/vendor/autoload.php'; |
| 17 | 17 | |
@@ -63,24 +63,24 @@ discard block |
||
| 63 | 63 | $this->upgrade(); |
| 64 | 64 | } else { |
| 65 | 65 | copy( |
| 66 | - $_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env.dist', |
|
| 67 | - $_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env' |
|
| 66 | + $_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env.dist', |
|
| 67 | + $_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env' |
|
| 68 | 68 | ); |
| 69 | 69 | } |
| 70 | 70 | |
| 71 | 71 | |
| 72 | - $sql_file = dirname($_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name).'/sql/install.sql'; |
|
| 72 | + $sql_file = dirname($_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name).'/sql/install.sql'; |
|
| 73 | 73 | $this->loadSQLFile($sql_file); |
| 74 | 74 | |
| 75 | 75 | try { |
| 76 | - $envFile = new Dotenv\Dotenv($_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name); |
|
| 76 | + $envFile = new Dotenv\Dotenv($_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name); |
|
| 77 | 77 | $envFile->load(); |
| 78 | 78 | } catch (\Exception $exception) { |
| 79 | - $this->context->controller->errors[] = $this->l('Unable to read file') . |
|
| 80 | - ' ' . $_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env ' . |
|
| 79 | + $this->context->controller->errors[] = $this->l('Unable to read file'). |
|
| 80 | + ' '.$_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env '. |
|
| 81 | 81 | $this->l('Ensure that the file exists and have the correct permissions'); |
| 82 | - $this->dotEnvError = $this->l('Unable to read file') . |
|
| 83 | - ' ' . $_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env ' . |
|
| 82 | + $this->dotEnvError = $this->l('Unable to read file'). |
|
| 83 | + ' '.$_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env '. |
|
| 84 | 84 | $this->l('Ensure that the file exists and have the correct permissions'); |
| 85 | 85 | } |
| 86 | 86 | |
@@ -149,16 +149,16 @@ discard block |
||
| 149 | 149 | public function upgrade() |
| 150 | 150 | { |
| 151 | 151 | |
| 152 | - if (!is_writable($_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env')) { |
|
| 152 | + if (!is_writable($_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env')) { |
|
| 153 | 153 | return false; |
| 154 | 154 | } |
| 155 | - $envFileVariables = $this->readEnvFileAsArray($_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env'); |
|
| 156 | - $distFileVariables = $this->readEnvFileAsArray($_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env.dist'); |
|
| 157 | - $distFile = Tools::file_get_contents($_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env.dist'); |
|
| 155 | + $envFileVariables = $this->readEnvFileAsArray($_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env'); |
|
| 156 | + $distFileVariables = $this->readEnvFileAsArray($_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env.dist'); |
|
| 157 | + $distFile = Tools::file_get_contents($_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env.dist'); |
|
| 158 | 158 | |
| 159 | 159 | $newEnvFileArr = array_merge($distFileVariables, $envFileVariables); |
| 160 | 160 | $newEnvFile = $this->replaceEnvFileValues($distFile, $newEnvFileArr); |
| 161 | - file_put_contents($_SERVER['DOCUMENT_ROOT'] . '/modules/' . $this->name . '/.env', $newEnvFile); |
|
| 161 | + file_put_contents($_SERVER['DOCUMENT_ROOT'].'/modules/'.$this->name.'/.env', $newEnvFile); |
|
| 162 | 162 | return true; |
| 163 | 163 | } |
| 164 | 164 | |
@@ -201,8 +201,8 @@ discard block |
||
| 201 | 201 | $from = strpos($envFile, $key); |
| 202 | 202 | if ($from !== false) { |
| 203 | 203 | $to = strpos($envFile, '#', $from); |
| 204 | - $fromReplace = Tools::substr($envFile, $from, (($to - $from)-1)); |
|
| 205 | - $toReplace = $key . '=' . $value; |
|
| 204 | + $fromReplace = Tools::substr($envFile, $from, (($to - $from) - 1)); |
|
| 205 | + $toReplace = $key.'='.$value; |
|
| 206 | 206 | $envFile = str_replace($fromReplace, $toReplace, $envFile); |
| 207 | 207 | } |
| 208 | 208 | } |
@@ -244,9 +244,9 @@ discard block |
||
| 244 | 244 | $cart = $this->context->cart; |
| 245 | 245 | $currency = new Currency($cart->id_currency); |
| 246 | 246 | $availableCurrencies = array('EUR'); |
| 247 | - $pmtDisplayMinAmount = getenv('PMT_DISPLAY_MIN_AMOUNT'); |
|
| 247 | + $pmtDisplayMinAmount = getenv('PMT_DISPLAY_MIN_AMOUNT'); |
|
| 248 | 248 | $pmtPublicKey = Configuration::get('pmt_public_key'); |
| 249 | - $pmtPrivateKey = Configuration::get('pmt_private_key'); |
|
| 249 | + $pmtPrivateKey = Configuration::get('pmt_private_key'); |
|
| 250 | 250 | |
| 251 | 251 | return ( |
| 252 | 252 | $cart->getOrderTotal() >= $pmtDisplayMinAmount && |
@@ -309,7 +309,7 @@ discard block |
||
| 309 | 309 | $paymentOption |
| 310 | 310 | ->setCallToActionText($pmtTitle) |
| 311 | 311 | ->setAction($link->getModuleLink('paylater', 'payment')) |
| 312 | - ->setLogo($this->getPathUri(). 'logo.gif') |
|
| 312 | + ->setLogo($this->getPathUri().'logo.gif') |
|
| 313 | 313 | ->setModuleName(__CLASS__) |
| 314 | 314 | ; |
| 315 | 315 | |
@@ -343,7 +343,7 @@ discard block |
||
| 343 | 343 | 'input' => array( |
| 344 | 344 | array( |
| 345 | 345 | 'name' => 'pmt_is_enabled', |
| 346 | - 'type' => (version_compare(_PS_VERSION_, '1.6')<0) ?'radio' :'switch', |
|
| 346 | + 'type' => (version_compare(_PS_VERSION_, '1.6') < 0) ? 'radio' : 'switch', |
|
| 347 | 347 | 'label' => $this->l('Module is enabled'), |
| 348 | 348 | 'prefix' => '<i class="icon icon-key"></i>', |
| 349 | 349 | 'class' => 't', |
@@ -383,7 +383,7 @@ discard block |
||
| 383 | 383 | ), |
| 384 | 384 | array( |
| 385 | 385 | 'name' => 'pmt_simulator_is_enabled', |
| 386 | - 'type' => (version_compare(_PS_VERSION_, '1.6')<0) ?'radio' :'switch', |
|
| 386 | + 'type' => (version_compare(_PS_VERSION_, '1.6') < 0) ? 'radio' : 'switch', |
|
| 387 | 387 | 'label' => $this->l('Simulator is enabled'), |
| 388 | 388 | 'prefix' => '<i class="icon icon-key"></i>', |
| 389 | 389 | 'class' => 't', |
@@ -502,7 +502,7 @@ discard block |
||
| 502 | 502 | $message = $this->displayError($this->dotEnvError); |
| 503 | 503 | } |
| 504 | 504 | |
| 505 | - $logo = $this->getPathUri(). 'views/img/logo_pagamastarde.png'; |
|
| 505 | + $logo = $this->getPathUri().'views/img/logo_pagamastarde.png'; |
|
| 506 | 506 | $tpl = $this->local_path.'views/templates/admin/config-info.tpl'; |
| 507 | 507 | $this->context->smarty->assign(array( |
| 508 | 508 | 'logo' => $logo, |
@@ -679,10 +679,10 @@ discard block |
||
| 679 | 679 | */ |
| 680 | 680 | public function checkLogoExists() |
| 681 | 681 | { |
| 682 | - $logo = _PS_MODULE_DIR_ . '/onepagecheckoutps/views/img/payments/'. Tools::strtolower(__CLASS__). '.png'; |
|
| 683 | - if (!file_exists($logo) && is_dir(_PS_MODULE_DIR_ . '/onepagecheckoutps/views/img/payments')) { |
|
| 682 | + $logo = _PS_MODULE_DIR_.'/onepagecheckoutps/views/img/payments/'.Tools::strtolower(__CLASS__).'.png'; |
|
| 683 | + if (!file_exists($logo) && is_dir(_PS_MODULE_DIR_.'/onepagecheckoutps/views/img/payments')) { |
|
| 684 | 684 | copy( |
| 685 | - _PS_PAYLATER_DIR . '/views/img/logo-64x64.png', |
|
| 685 | + _PS_PAYLATER_DIR.'/views/img/logo-64x64.png', |
|
| 686 | 686 | $logo |
| 687 | 687 | ); |
| 688 | 688 | } |