Minor code fixes in onestring view

* don’t use die to print Json::output
* don’t use $locale as a local variable name (already defined at global scope)