CC-4895: Remove all json die() statements from code

- removed json_encode