refactor code as remarked + add uuid to test deck

This commit is contained in:
Rene Fischer 2020-07-27 00:17:04 +02:00
parent 73604d9f14
commit eb24802d37
No known key found for this signature in database
GPG key ID: 5D8E12AC54D3C1B5
2 changed files with 3 additions and 4 deletions

View file

@ -1,7 +1,8 @@
{
"meta": {
"author": "Niko Lockenvitz & Rene-Pascal Fischer",
"version": "1.1.1"
"version": "1.1.1",
"uuid": "6d4b5420-3c3e-42bc-addd-019597fd438b"
},
"decks": {
"d0": {

View file

@ -87,9 +87,7 @@ export function addDecksFromJSON(
addedDecksAndCards.push({ name, numberOfCards: cards.length });
}
const version = fileContent.meta.version
? fileContent.meta.version
: undefined;
const version = fileContent?.meta?.version;
showAddedDecksConfirmation(
context,