Skip to content

Commit

Permalink
fix(runtime): handle nilptr in func (*cxRequestBeforeRequest) Freeze() (
Browse files Browse the repository at this point in the history
#268)

Signed-off-by: Pierre Fenoll <[email protected]>
  • Loading branch information
fenollp authored Nov 14, 2024
1 parent 9ddd96d commit 55add0c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Tagfile
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.52.0
0.52.1
4 changes: 3 additions & 1 deletion pkg/runtime/cx_request_before_request.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,9 @@ func (cr *cxRequestBeforeRequest) Truth() starlark.Bool { return true }
func (cr *cxRequestBeforeRequest) Type() string { return cr.ty }

func (cr *cxRequestBeforeRequest) Freeze() {
cr.body.Freeze()
if cr.body != nil {
cr.body.Freeze()
}
cr.headers.Freeze()
cr.method.Freeze()
cr.url.Freeze()
Expand Down

0 comments on commit 55add0c

Please sign in to comment.