Fix: Usage of context during event callbacks

Replaced one-off method with new method from defer.js to bind
the context to the callback. Also, the trigger function was
trying to access the wrong variable (ctx vs context) when pulling
the execution context out of the event map.

Signed-off-by: Kevin Conway <kevinjacobconway@gmail.com>
Merge pull request #5 from kevinconway/fix_context

Fix: Usage of context during event callbacks