Skip to content

Commit

Permalink
[klarna-invoice] fix payment factory, always live cannot set sandbox …
Browse files Browse the repository at this point in the history
…mode.
  • Loading branch information
makasim committed Mar 13, 2015
1 parent ec92ec5 commit af2fc8e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion PaymentFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ public function createConfig(array $config = array())
$config['payum.api'] = function (ArrayObject $config) {
$config->validateNotEmpty($config['payum.required_options']);

$config['mode'] = null === $config['sandbox'] ? \Klarna::BETA : \Klarna::LIVE;
$config['mode'] = $config['sandbox'] ? \Klarna::BETA : \Klarna::LIVE;

if (null === $country = \KlarnaCountry::fromCode($config['country'])) {
throw new LogicException(sprintf('Given %s country code is not valid. Klarna cannot recognize it.', $config['country']));
Expand Down

0 comments on commit af2fc8e

Please sign in to comment.