Test Failed
Push — develop ( f54e3f...92cf2c )
by Reüel
02:42
created

src/ConfigFactory.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace Pronamic\WordPress\Pay\Gateways\Nocks;
4
5
use Pronamic\WordPress\Pay\Core\GatewayConfigFactory;
6
7
/**
8
 * Title: Nocks config factory
9
 * Description:
10
 * Copyright: 2005-2019 Pronamic
11
 * Company: Pronamic
12
 *
13
 * @author  Reüel van der Steege
14
 * @version 2.0.0
15
 * @since   1.0.0
16
 */
17
class ConfigFactory extends GatewayConfigFactory {
18
	public function get_config( $post_id ) {
19
		$config = new Config();
20
21
		$config->post_id          = $post_id;
22
		$config->mode             = get_post_meta( $post_id, '_pronamic_gateway_mode', true );
0 ignored issues
show
The function get_post_meta was not found. Maybe you did not declare it correctly or list all dependencies? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

22
		$config->mode             = /** @scrutinizer ignore-call */ get_post_meta( $post_id, '_pronamic_gateway_mode', true );
Loading history...
23
		$config->access_token     = get_post_meta( $post_id, '_pronamic_gateway_nocks_access_token', true );
24
		$config->merchant_profile = get_post_meta( $post_id, '_pronamic_gateway_nocks_merchant_profile', true );
25
26
		return $config;
27
	}
28
}
29