From 87177d0d7f44debb16fd610909e3ea662a487e01 Mon Sep 17 00:00:00 2001 From: Jean-Patrick Guerrero Date: Thu, 16 Apr 2020 16:20:25 +0200 Subject: [PATCH] More safeguard --- init.lua | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/init.lua b/init.lua index b43f443..d7cbdb7 100644 --- a/init.lua +++ b/init.lua @@ -1476,8 +1476,10 @@ local function show_item(def) end local function get_init_items() - if autocache == false then - init_items = dslz(storage:get "init_items") + local init_items_bak = storage:get "init_items" + + if autocache == false and init_items_bak then + init_items = dslz(init_items_bak) fuel_cache = dslz(storage:get "fuel_cache") usages_cache = dslz(storage:get "usages_cache") recipes_cache = dslz(storage:get "recipes_cache")