|
|
@@ -57,7 +57,9 @@ class WorkerWeChatPayService extends BasePayService
|
|
|
$this->terminal = $terminal;
|
|
|
$this->config = WeChatConfigService::getPayConfigByTerminal($terminal);
|
|
|
$this->app = new Application($this->config);
|
|
|
- $this->auth = MasterWorkerAuth::where(['worker_id' => $userId, 'terminal' => $terminal])->findOrEmpty();
|
|
|
+ if ($userId !== null) {
|
|
|
+ $this->auth = MasterWorkerAuth::where(['worker_id' => $userId, 'terminal' => $terminal])->findOrEmpty();
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
|