changes to doc code for hasChangesChanged and Q.end -> Q.done