deferredQuery now has a parameterizable callback