Skip to content

Commit

Permalink
fix: Revert faker pointer change
Browse files Browse the repository at this point in the history
  • Loading branch information
erezrokah committed Mar 7, 2025
1 parent 1298b36 commit 14e968f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion faker/faker.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@ type faker struct {

var errEFaceNotAllowed = errors.New("any not allowed")

func (f *faker) getFakedValue(a any) (reflect.Value, error) {
func (f faker) getFakedValue(a any) (reflect.Value, error) {
t := reflect.TypeOf(a)
if t == nil {
return reflect.Value{}, errEFaceNotAllowed
}
//nolint:revive
f.maxDepth--
if f.maxDepth < 0 {
return reflect.Value{}, errors.New("max_depth reached")
Expand Down

0 comments on commit 14e968f

Please sign in to comment.