[JENKINS-13546]: Uniformize build response for request of type "application/json"

When requesting a build using a request of type "application/json", it returns an object
which describes things about the build target, and the scheduled item (.queueItem).
This now works for build with or without parameters.

PS: Commit is not a fix, as user Sune Keller stated that sometimes the "queueItem" is null.