adding a deferred handler