refactored getJSON calls