You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The first one should probably throw an error (a JS exception at least).
The for the second one- the problem is that when callAction: is used, it looks at the current thread and whatever COScript is around and uses that jscontext. That's a bad idea if it's not the context which the COSTarget was created for. So initWithJSFunction: should somehow grab the current COScript that it's executing in and stash that in a weak ivar.
Activity
ccgus commentedon May 24, 2014
The first one should probably throw an error (a JS exception at least).
The for the second one- the problem is that when callAction: is used, it looks at the current thread and whatever COScript is around and uses that jscontext. That's a bad idea if it's not the context which the COSTarget was created for. So initWithJSFunction: should somehow grab the current COScript that it's executing in and stash that in a weak ivar.