mirror of
https://github.com/jwetzell/showbridge-go.git
synced 2026-04-27 05:15:47 +00:00
use errors.New when not formatting
This commit is contained in:
@@ -2,7 +2,7 @@ package processor
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"errors"
|
||||
"io"
|
||||
"net/http"
|
||||
|
||||
@@ -17,7 +17,7 @@ func (hre *HTTPResponseEncode) Process(ctx context.Context, payload any) (any, e
|
||||
payloadResponse, ok := payload.(*http.Response)
|
||||
|
||||
if !ok {
|
||||
return nil, fmt.Errorf("http.response.encode processor only accepts an http.Response")
|
||||
return nil, errors.New("http.response.encode processor only accepts an http.Response")
|
||||
}
|
||||
defer payloadResponse.Body.Close()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user