refactor(httpx): drop duplicate WriteError, add WriteInternal

This commit is contained in:
kk10
2026-10-05 11:41:34 +03:00
parent 5d6f5a397f
commit b94e7813ee
6 changed files with 19 additions and 77 deletions
+10
View File
@@ -22,3 +22,13 @@ func WriteError(w http.ResponseWriter, status int, code dto.ErrorCode, message,
},
})
}
func WriteInternal(w http.ResponseWriter, requestID string) {
WriteError(
w,
http.StatusInternalServerError,
dto.ErrorCodeInternalError,
"internal server error",
requestID,
)
}