Skip to content

Commit

Permalink
Use map filename if no id detected when generating uuid
Browse files Browse the repository at this point in the history
  • Loading branch information
rrgeorge committed Sep 12, 2021
1 parent 2cc7836 commit 6adbc83
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion ddb.js
Original file line number Diff line number Diff line change
Expand Up @@ -1778,7 +1778,7 @@ function displayModal(path,id) {
console.log(`This might be a map: ${mapUrl}`)
let playerMap = {
_name: "map",
_attrs: { id: uuid5(`https://www.dndbeyond.com/${book.sourceURL}/image/${figure.id}`, uuid5.URL), parent: (this.mapsloc!="group")? page.page._attrs.id : mapgroup, sort: mapsort},
_attrs: { id: uuid5(`https://www.dndbeyond.com/${book.sourceURL}/image/${figure.id||mapUrl}`, uuid5.URL), parent: (this.mapsloc!="group")? page.page._attrs.id : mapgroup, sort: mapsort},
_content: [
{ name: he.decode(mapTitle) },
{ slug: slugify(mapTitle) },
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "encounterlog",
"productName": "EncounterLog",
"version": "2.1.5",
"version": "2.1.6",
"description": "Connect D&D Beyond to EncounterPlus",
"repository": {
"type": "git",
Expand Down Expand Up @@ -137,7 +137,7 @@
"jstoxml": "^2.0.6",
"mac": "^0.4.0",
"opencv4nodejs-prebuilt": "5.3.3",
"sharp": "^0.29.0",
"sharp": "^0.29.1",
"slugify": "^1.5.3",
"tmp": "^0.2.1",
"uuid": "^8.3.2",
Expand Down
18 changes: 9 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2369,10 +2369,10 @@ node-addon-api@^3.0.0:
resolved "https://registry.npmjs.org/node-addon-api/-/node-addon-api-3.2.1.tgz"
integrity sha512-mmcei9JghVNDYydghQmeDX8KoAm0FAiYyIcUt/N4nhyAipB17pllZQDOJD2fotxABnt4Mdz+dKTO7eftLg4d0A==

node-addon-api@^4.0.0:
version "4.0.0"
resolved "https://registry.npmjs.org/node-addon-api/-/node-addon-api-4.0.0.tgz"
integrity sha512-ALmRVBFzfwldBfk3SbKfl6+PVMXiCPKZBEfsJqB/EjXAMAI+MfFrEHR+GMRBuI162DihZ1QjEZ8ieYKuRCJ8Hg==
node-addon-api@^4.1.0:
version "4.1.0"
resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-4.1.0.tgz#f1722f1f60793584632ffffb79e12ca042c48bd0"
integrity sha512-Zz1o1BDX2VtduiAt6kgiUl8jX1Vm3NMboljFYKQJ6ee8AGfiTvM2mlZFI3xPbqjs80rCQgiVJI/DjQ/1QJ0HwA==

node-fetch@^2.3.0, node-fetch@^2.6.1:
version "2.6.1"
Expand Down Expand Up @@ -2877,14 +2877,14 @@ set-blocking@~2.0.0:
resolved "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz"
integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc=

sharp@^0.29.0:
version "0.29.0"
resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.29.0.tgz#1fa302bd5f60292138c823aa0905609f64d710ba"
integrity sha512-mdN1Up0eN+SwyForPls59dWO0nx64J1XRQYy5ZiKSADAccGYCB10UAGJHSVG9VObzJdhHqrVJzQcq6gx8USyoA==
sharp@^0.29.1:
version "0.29.1"
resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.29.1.tgz#f60b50f24f399464a24187c86bd2da41aae50b85"
integrity sha512-DpgdAny9TuS+oWCQ7MRS8XyY9x6q1+yW3a5wNx0J3HrGuB/Jot/8WcT+lElHY9iJu2pwtegSGxqMaqFiMhs4rQ==
dependencies:
color "^4.0.1"
detect-libc "^1.0.3"
node-addon-api "^4.0.0"
node-addon-api "^4.1.0"
prebuild-install "^6.1.4"
semver "^7.3.5"
simple-get "^3.1.0"
Expand Down

0 comments on commit 6adbc83

Please sign in to comment.