tile38 icon indicating copy to clipboard operation
tile38 copied to clipboard

fix: FSET lowercasing upper case fields

Open iwpnd opened this issue 1 year ago • 1 comments

Please ensure you adhere to every item in this list

Figured it is minor enough to not wait your okay on this @tidwall . :pray:

  • [x] This PR was pre-approved by the project maintainer
  • [x] I have self-reviewed the code
  • [x] I have added all necessary tests

Describe your changes

moving the string.ToLower() conversion into the switch statement instead of mutating the input argument ensures field cases are preserved. added additional tests.

[...]
	for i := 3; i < len(args); i++ {
		arg := args[i]
		switch strings.ToLower(arg) {
		case "xx":
			xx = true
		default:
			fkey := arg
			i++
                        [...]

Issue number and link

fixes #741

iwpnd avatar May 25 '24 10:05 iwpnd

An unrelated test appears to be failing. Looks to be flaky :eyes:

iwpnd avatar May 25 '24 11:05 iwpnd