Are you sure the function will be called ?
I think it should be something like:
```coffee
do @onClose
```
or
```coffee
@onClose()
```