fix: style

This commit is contained in:
kriss 2018-02-27 13:30:07 +08:00
parent fd3272c309
commit 413d5511de
2 changed files with 2 additions and 2 deletions

View File

@ -70,7 +70,7 @@ class Wechat implements GatewayApplicationInterface
public function __construct(Config $config)
{
$this->config = $config;
$this->mode = $this->config->get('mode', Wechat::MODE_NORMAL);
$this->mode = $this->config->get('mode', self::MODE_NORMAL);
$this->gateway = Support::baseUri($this->mode);
$this->payload = [
'appid' => $this->config->get('app_id', ''),

View File

@ -105,7 +105,7 @@ class Support
$payload['appid'] = $config->get($type, '');
$mode = $config->get('mode', Wechat::MODE_NORMAL);
if ($mode === Wechat::MODE_SERVICE) {
$payload['sub_appid'] = $config->get('sub_' . $type, '');
$payload['sub_appid'] = $config->get('sub_'.$type, '');
}
unset($payload['notify_url'], $payload['trade_type'], $payload['type']);