Comcast / rulio

Rulio
Apache License 2.0
336 stars 59 forks source link

Inject special variables earlier so that condition code can use them #6

Closed jsccast closed 8 years ago

jsccast commented 8 years ago

Currently some special variables like event and location are injected (if there's no conflict) into an action's Javascript environment. Should inject these bindings earlier so that a code condition can use these bindings.

Fix should be easy. See EvalRuleCondition.Do() in core/events.go. Move the binding code up a little.

wingdog commented 8 years ago

Good timing, I have a rule that can use this feature.