Constructor with 1 parameter always = 'No error'
Constructor with 1 parameter always = 'No error'

If you call `new JSONException('message');` the $code will be null which
== JSON_ERROR_NONE i.e. int(0). Switch does not do strict compare (===).

Also, make sure to not overwrite the custom message if it's not falsy.

Picked from 189e367d45

symphonycms/symphony-2,jensscherbl/symphony,bauhouse/sym-todo-list,jensscherbl/symphony,michael-e/symphony-2,symphonycms/symphony-2,bauhouse/sym-todo-list,michael-e/symphony-2