Skip to content

Commit

Permalink
refactor: update function interface
Browse files Browse the repository at this point in the history
  • Loading branch information
Kikobeats committed Feb 22, 2022
1 parent 0b3f6f4 commit 7395159
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
4 changes: 2 additions & 2 deletions recipes/by-feature/excerpt.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

const microlink = require('@microlink/function')

const code = `async ({ query, html }) => {
const code = `async ({ url, html }) => {
const { Readability } = require('@mozilla/readability')
const { JSDOM, VirtualConsole } = require('jsdom')
const dom = new JSDOM(html, {
url: query.url,
url,
virtualConsole: new VirtualConsole()
})
Expand Down
4 changes: 1 addition & 3 deletions test/by-feature.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,7 @@ test('get html', async t => {
})

test('get excerpt', async t => {
const { value } = await excerpt(excerpt.meta.examples[0], {
apiKey
})
const { value } = await excerpt(excerpt.meta.examples[0], { apiKey })
t.true(ow.isValid(value, ow.string.not.empty))
})

Expand Down

0 comments on commit 7395159

Please sign in to comment.