- 将 exit(json_encode($data)) 替换为 returnJson($data) 函数 - 在 switch 语句中添加 break 语句,避免代码执行顺序错误 - 统一 JSON 返回格式,提高代码可维护性