Skip to content

Commit

Permalink
fixup! js/common: Helper for Object.freeze from Go
Browse files Browse the repository at this point in the history
  • Loading branch information
codebien committed Apr 20, 2022
1 parent 4346b79 commit 16e141b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/common/frozen_object.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ func FreezeObject(rt *goja.Runtime, obj goja.Value) error {
global := rt.GlobalObject().Get("Object").ToObject(rt)
freeze, ok := goja.AssertFunction(global.Get("freeze"))
if !ok {
panic(fmt.Errorf("failed to get the Object.freeze function from the runtime"))
panic("failed to get the Object.freeze function from the runtime")
}
isFrozen, ok := goja.AssertFunction(global.Get("isFrozen"))
if !ok {
panic(fmt.Errorf("failed to get the Object.isFrozen function from the runtime"))
panic("failed to get the Object.isFrozen function from the runtime")
}
fobj := &freezing{
global: global,
Expand Down

0 comments on commit 16e141b

Please sign in to comment.