code cleanup and default loading of json data.