Skip to content

Commit

Permalink
Merge pull request #9 from Ryanair/feature/remove-dangerous-traces
Browse files Browse the repository at this point in the history
HTTP: remove trace loggers in successful path
  • Loading branch information
somolinosm authored Aug 31, 2021
2 parents f276d04 + 3dea7c1 commit 5a3f532
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions http/responses.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,12 @@ import (
)

func ToResponse(rawData interface{}, status int) events.APIGatewayV2HTTPResponse {
log.Debug("RawData: ", rawData)
var response string
jsonBytes, err := json.Marshal(rawData)
if err != nil {
log.Error("Error converting to json ", rawData)
response = "[]"
} else {
log.Debug("JSON:", string(jsonBytes))
response = string(jsonBytes)
if response == "null" {
response = "[]"
Expand Down

0 comments on commit 5a3f532

Please sign in to comment.