Fix "Body should be a JSON Array" issue

The pull request http://github.com/KnpLabs/php-github-api/pull/40 fixed some issues with empty parameters, but caused a regression on other functionalities (see URL for a more detailed explanation).

This modification only forces JSON-objects to be generated when the parameters are empty. This should fix the newly created issues as well as not regress the fix for the previous issue.