some cleanup, return jsonOutpu() not used here, add some comments, whitespae