Refactor: change the jsonResult to just take in text