Skip to content

Commit

Permalink
refresh token in links (#4)
Browse files Browse the repository at this point in the history
* include token in refresh

* remove debugging

* safe regex
  • Loading branch information
natzcam authored Jan 15, 2025
1 parent 42da86a commit 89cb2a6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ module.exports = class HypercoreBlobServer {
}

refreshLink (link) {
return link.replace(/:\d+\//, ':' + this.port + '/')
return link.replace(/:\d+\//, ':' + this.port + '/').replace(/token=([^&]+)/, 'token=' + this.token)
}

getLink (key, opts = {}) {
Expand Down

0 comments on commit 89cb2a6

Please sign in to comment.