From 22172ac66f537b32fdaf41ae49283d5bcc7811e7 Mon Sep 17 00:00:00 2001 From: Hide_D Date: Sun, 2 Oct 2022 19:39:35 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20null=20coalesing=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hwe/sammo/GeneralAI.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hwe/sammo/GeneralAI.php b/hwe/sammo/GeneralAI.php index 3604180f..9c95fc08 100644 --- a/hwe/sammo/GeneralAI.php +++ b/hwe/sammo/GeneralAI.php @@ -117,8 +117,8 @@ class GeneralAI $nationStor = KVStorage::getStorage($db, $this->nation['nation'], 'nation_env'); $nationStor->cacheValues(['npc_nation_policy', 'npc_general_policy', 'prev_income_gold', 'prev_income_rice']); - $this->nationPolicy = new AutorunNationPolicy($general, $this->env['autorun_user']['options'] ?? null, $nationStor->getValue('npc_nation_policy'), $this->env['npc_nation_policy'] ?? null, $this->nation, $this->env); - $this->generalPolicy = new AutorunGeneralPolicy($general, $this->env['autorun_user']['options'] ?? null, $nationStor->getValue('npc_general_policy'), $this->env['npc_general_policy'] ?? null, $this->nation, $this->env); + $this->nationPolicy = new AutorunNationPolicy($general, $this->env['autorun_user']['options'] ?? null, $nationStor->getValue('npc_nation_policy'), ($this->env['npc_nation_policy']) ?? null, $this->nation, $this->env); + $this->generalPolicy = new AutorunGeneralPolicy($general, $this->env['autorun_user']['options'] ?? null, $nationStor->getValue('npc_general_policy'), ($this->env['npc_general_policy']) ?? null, $this->nation, $this->env); $prevIncomeGold = $nationStor->prev_income_gold ?? 1000; $prevIncomeRice = $nationStor->prev_income_rice ?? 1000;