Skip to content

Commit

Permalink
Merge pull request #25
Browse files Browse the repository at this point in the history
Fix syntax error and remove unused methods #187878612
  • Loading branch information
r-martins authored Jul 1, 2024
2 parents 77c314f + 6693f43 commit ac798da
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,4 @@ interface RicardoMartins_PagBank_Api_Connect_PublicKeyInterface
* Used to save the public key.
*/
const PUBLIC_KEY_CONFIG_PATH = 'payment/ricardomartins_pagbank/public_key';

/**
* @param string $connectKey
* @return string
*/
public function createPublicKey(string $connectKey): string;

/**
* @param string $publicKey
* @return void
*/
public function savePublicKey(string $publicKey): void;
}
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function generatePublicKey(Varien_Event_Observer $observer)
}

try {
Mage::getConfig()->saveConfig('payment/ricardomartins_pagbank/public_key', $publicKey);
Mage::getConfig()->saveConfig(RicardoMartins_PagBank_Api_Connect_PublicKeyInterface::PUBLIC_KEY_CONFIG_PATH, $publicKey);
} catch (\Exception $e) {
$helper->writeLog(sprintf('Error saving public key: %s', $e->getMessage()));
throw new \Exception(__('Error saving public key: %s', $e->getMessage()));
Expand Down

0 comments on commit ac798da

Please sign in to comment.