implementing Q deferred