mirror of
https://github.com/pion/webrtc.git
synced 2025-10-05 15:16:52 +08:00

Use IsUndefined() and IsNull() to check for undefined and null js.Value when building with Go 1.14.
14 lines
196 B
Go
14 lines
196 B
Go
// +build js,!go1.14
|
|
|
|
package webrtc
|
|
|
|
import "syscall/js"
|
|
|
|
func jsValueIsUndefined(v js.Value) bool {
|
|
return v == js.Undefined()
|
|
}
|
|
|
|
func jsValueIsNull(v js.Value) bool {
|
|
return v == js.Null()
|
|
}
|