Promise fixes

Adapting stomp for new promise api
Referencing $this inside a closure is not supported by PHP 5.3