Update dependencies (#20)
All checks were successful
Lint / pre-commit Linting (push) Successful in 29s

- @actions/core
- glob
- screeps-api

Reviewed-on: #20
Co-authored-by: Philipp Horstenkamp <philipp@horstenkamp.de>
Co-committed-by: Philipp Horstenkamp <philipp@horstenkamp.de>
This commit is contained in:
2025-04-12 13:43:45 +02:00
committed by Philipp Horstenkamp
parent 1aa7be2b73
commit 318515b9c4
634 changed files with 49143 additions and 4925 deletions

View File

@ -229,7 +229,11 @@ class Request {
onBodySent (chunk) {
if (this[kHandler].onBodySent) {
return this[kHandler].onBodySent(chunk)
try {
return this[kHandler].onBodySent(chunk)
} catch (err) {
this.abort(err)
}
}
}
@ -239,7 +243,11 @@ class Request {
}
if (this[kHandler].onRequestSent) {
return this[kHandler].onRequestSent()
try {
return this[kHandler].onRequestSent()
} catch (err) {
this.abort(err)
}
}
}
@ -263,14 +271,23 @@ class Request {
channels.headers.publish({ request: this, response: { statusCode, headers, statusText } })
}
return this[kHandler].onHeaders(statusCode, headers, resume, statusText)
try {
return this[kHandler].onHeaders(statusCode, headers, resume, statusText)
} catch (err) {
this.abort(err)
}
}
onData (chunk) {
assert(!this.aborted)
assert(!this.completed)
return this[kHandler].onData(chunk)
try {
return this[kHandler].onData(chunk)
} catch (err) {
this.abort(err)
return false
}
}
onUpgrade (statusCode, headers, socket) {
@ -289,7 +306,13 @@ class Request {
if (channels.trailers.hasSubscribers) {
channels.trailers.publish({ request: this, trailers })
}
return this[kHandler].onComplete(trailers)
try {
return this[kHandler].onComplete(trailers)
} catch (err) {
// TODO (fix): This might be a bad idea?
this.onError(err)
}
}
onError (error) {
@ -303,6 +326,7 @@ class Request {
return
}
this.aborted = true
return this[kHandler].onError(error)
}