Skip to content

Commit

Permalink
Merge pull request #26 from microlinkhq/next
Browse files Browse the repository at this point in the history
refactor: rewrite to support node12
  • Loading branch information
Kikobeats committed Jun 21, 2022
2 parents 9b73f22 + 437d933 commit 8c38914
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions index.js
Expand Up @@ -17,12 +17,13 @@ class KeyvS3 extends EventEmitter {
this.hostname = hostname != null ? hostname : namespace
this.s3client = s3client != null ? s3client : new S3Client(opts)
this.got =
got ??
require('got').extend({
...gotOpts,
retry: opts.maxAttempts ?? gotOpts?.retry,
timeout: opts.requestHandler?.socketTimeout ?? gotOpts?.timeout
})
got != null
? got
: require('got').extend({
...gotOpts,
retry: opts.maxAttempts ?? gotOpts?.retry,
timeout: opts.requestHandler?.socketTimeout ?? gotOpts?.timeout
})
}

filename (key) {
Expand Down

0 comments on commit 8c38914

Please sign in to comment.