Handle API module with no parameters

Prints a localized warning message instead of JavaScript error.
Also fix jshint errors in UiBuilder.js and i18n.php trailing whitespace.

Bug: 61793
Change-Id: Ic8b4c2e0488e5d6e3f1b3ef2c5ff2b1dcdf031b1