Skip to content

Commit 5f07e77

Browse files
author
Eric
committed
fixed Toggle() to match jquery definition
Jquery (since 1.0) has a Toggle method with optional parameters, and various options http://api.jquery.com/toggle/
1 parent 14d953b commit 5f07e77

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

jquery.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -425,8 +425,8 @@ func (j JQuery) Hide() JQuery {
425425
return j
426426
}
427427

428-
func (j JQuery) Toggle(showOrHide bool) JQuery {
429-
j.o = j.o.Call("toggle", showOrHide)
428+
func (j JQuery) Toggle(i ...interface{}) JQuery {
429+
j.o = j.o.Call("toggle", i...)
430430
return j
431431
}
432432

0 commit comments

Comments
 (0)