Fixed: then() was used instead of done() when processing deferred objects