config = $config; $this->json = $json; } /** * Retrieves the config that should be used by the block * * @return string * @since 100.3.0 */ public function getPaymentConfig(): string { $payment = $this->config->getConfig()['payment']; $config = $payment[$this->getMethodCode()]; $config['code'] = $this->getMethodCode(); return $this->json->serialize($config); } /** * Returns the method code for this payment method * * @return string * @since 100.3.0 */ public function getMethodCode(): string { return Config::METHOD; } }