wrap result of walk(..) and other refactorings
parse JSON without callback