Skip to content

Commit

Permalink
Revert "Use second optional positional attribute (target) as generate…
Browse files Browse the repository at this point in the history
…d-file-name"

This reverts commit 00a8a69.
  • Loading branch information
ggrossetie committed Jun 13, 2020
1 parent 51a3c2e commit e6258e1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 22 deletions.
2 changes: 1 addition & 1 deletion src/fetch.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ module.exports.save = function (krokiDiagram, doc, target, vfs, krokiClient) {
const dirPath = getDirPath(doc)
const diagramUrl = krokiDiagram.getDiagramUri(krokiClient.getServerUrl())
const format = krokiDiagram.format
const diagramName = target ? `${target}.${format}` : `diag-${rusha.createHash().update(diagramUrl).digest('hex')}.${format}`
const diagramName = `diag-${rusha.createHash().update(diagramUrl).digest('hex')}.${format}`
const filePath = path.format({ dir: dirPath, base: diagramName })
let encoding
let mediaType
Expand Down
22 changes: 1 addition & 21 deletions test/test.spec.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit e6258e1

Please sign in to comment.