Преглед изворни кода

CustomerError

- refactoring
Alexey Kim пре 2 година
родитељ
комит
592aaef230
1 измењених фајлова са 1 додато и 2 уклоњено
  1. 1 2
      graphql/errors.go

+ 1 - 2
graphql/errors.go

@@ -14,9 +14,8 @@ var (
 )
 
 func CustomerError(code generated.CustomerErrorCode, err error, fields ...string) *generated.CustomerUserError {
-	k := code
 	return &generated.CustomerUserError{
-		Code:    &k,
+		Code:    &code,
 		Field:   fields,
 		Message: err.Error(),
 	}