Added error reporting to qRestAPI.
Don't take result object before calling waitForDone().
Fixed inverted logic for returning true on success.
Clean-up query results.
Merge pull request #2 from saschazelzer/backwards-compatible-error-handling

Added error reporting to qRestAPI.