jsObj.optString() will have the same effect with less code.