Skip to content

Commit

Permalink
Remove unimplemented JSHandle.getProperty API
Browse files Browse the repository at this point in the history
  • Loading branch information
ankur22 committed Apr 22, 2024
1 parent 90a6853 commit d6409e0
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
7 changes: 0 additions & 7 deletions browser/mapping.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,13 +208,6 @@ func mapJSHandle(vu moduleVU, jsh common.JSHandleAPI) mapping {
}
return dst, nil
},
"getProperty": func(propertyName string) *goja.Object {
var (
h = jsh.GetProperty(propertyName)
m = mapJSHandle(vu, h)
)
return rt.ToValue(m).ToObject(rt)
},
"jsonValue": jsh.JSONValue,
}
}
Expand Down
6 changes: 0 additions & 6 deletions common/js_handle.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ type JSHandleAPI interface {
Evaluate(pageFunc string, args ...any) any
EvaluateHandle(pageFunc string, args ...any) (JSHandleAPI, error)
GetProperties() (map[string]JSHandleAPI, error)
GetProperty(propertyName string) JSHandleAPI
JSONValue() (string, error)
ObjectID() cdpruntime.RemoteObjectID
}
Expand Down Expand Up @@ -156,11 +155,6 @@ func (h *BaseJSHandle) getProperties() (map[string]jsHandle, error) {
return props, nil
}

// GetProperty retreves a single property of the JS handle.
func (h *BaseJSHandle) GetProperty(_ string) JSHandleAPI {
return nil
}

// JSONValue returns a JSON version of this JS handle.
func (h *BaseJSHandle) JSONValue() (string, error) {
remoteObject := h.remoteObject
Expand Down

0 comments on commit d6409e0

Please sign in to comment.