[TASK] Switch to json_encode for file folder tree