Skip to content

Commit

Permalink
fix CI
Browse files Browse the repository at this point in the history
  • Loading branch information
75lb committed Aug 25, 2024
1 parent af38417 commit cdef559
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
6 changes: 4 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ const Cache = require('cache-point')
const DmdOptions = require('./lib/dmd-options')
const dmdVersion = require('./package').version
const FileSet = require('file-set')
const os = require('os')

/**
* Transforms doclet data into markdown documentation.
Expand All @@ -17,15 +18,16 @@ async function dmd (templateData, options) {
return generate(templateData, options)
} else {
try {
return dmd.cache.read([templateData, options, dmdVersion])
const result = await dmd.cache.read([templateData, options, dmdVersion])
return result
} catch (err) {
/* cache miss */
return generate(templateData, options)
}
}
}

dmd.cache = new Cache({ dir: path.join(require('os').tmpdir(), 'dmd') })
dmd.cache = new Cache({ dir: path.join(os.tmpdir(), 'dmd') })

async function generate (templateData, options) {
const fs = require('fs')
Expand Down
1 change: 0 additions & 1 deletion test/ddata/children.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,3 @@ test.set('_children', function () {
})

module.exports = { test, only, skip }

0 comments on commit cdef559

Please sign in to comment.