Skip to content

Commit

Permalink
Improve log
Browse files Browse the repository at this point in the history
  • Loading branch information
sam-lippert committed Dec 20, 2023
1 parent 1ccb35f commit 0032435
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export class Counter {
init.method = callback.method || init.method || init.body ? 'POST' : 'GET'
console.log({ url, init })
const data = await fetch(url, init)
console.log({ data: await data.text() })
console.log({ data: data.headers.get('content-type') ? await data.json() : await data.text() })
}
}
await this.state.storage.put('value', this.value)
Expand Down

0 comments on commit 0032435

Please sign in to comment.