diff --git a/load.js b/load.js index ae7b62a..1a195fb 100644 --- a/load.js +++ b/load.js @@ -1,4 +1,4 @@ -const DB_VERSION = 31; +const DB_VERSION = 32; // @See https://github.com/mdn/learning-area/blob/master/javascript/apis/client-side-storage/indexeddb/video-store/index.js let db; @@ -55,6 +55,9 @@ function clean_item(item) { item.skillpoints = [item.str, item.dex, item.int, item.def, item.agi]; item.has_negstat = item.str < 0 || item.dex < 0 || item.int < 0 || item.def < 0 || item.agi < 0; item.reqs = [item.strReq, item.dexReq, item.intReq, item.defReq, item.agiReq]; + if (item.slots === undefined) { + item.slots = 0 + } } }