Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
rfixupo
  • Loading branch information
ronag committed Nov 23, 2024
commit af0f34423fea5d13c8346a9791df0839e5b833a2
7 changes: 1 addition & 6 deletions lib/cache/sqlite-cache-store.js
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ class SqliteCacheStore {
const body = []
const store = this

const writable = new Writable({
return new Writable({
write (chunk, encoding, callback) {
if (typeof chunk === 'string') {
chunk = Buffer.from(chunk, encoding)
Expand All @@ -265,9 +265,6 @@ class SqliteCacheStore {
final (callback) {
store.prune()

/**
* @type {SqliteStoreValue | undefined}
*/
const existingValue = store.#findValue(key, true)
if (existingValue) {
// Updating an existing response, let's overwrite it
Expand Down Expand Up @@ -304,8 +301,6 @@ class SqliteCacheStore {
callback()
}
})

return writable
}

/**
Expand Down