Resolving when deferred with array of individual deferred resolve arguments; Made callFunction method efficient.