Skip to content

Commit

Permalink
staticcheck fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Brat-vseznamus committed Jan 21, 2025
1 parent 8628c27 commit a02a3fa
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions internal/tlcodegen/type_rw_maybe_php.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func (trw *TypeRWMaybe) PhpReadMethodCall(targetName string, bare bool, initIfDe
initIfDefault = false
}
bodyReader := trw.element.t.trw.PhpReadMethodCall(targetName, trw.element.bare, initIfDefault, args)
for i, _ := range bodyReader {
for i := range bodyReader {
bodyReader[i] = " " + bodyReader[i]
}
result = append(result, bodyReader...)
Expand Down Expand Up @@ -91,7 +91,7 @@ func (trw *TypeRWMaybe) PhpWriteMethodCall(targetName string, bare bool, args *T
}
{
bodyWriter := trw.element.t.trw.PhpWriteMethodCall(targetName, trw.element.bare, args)
for i, _ := range bodyWriter {
for i := range bodyWriter {
bodyWriter[i] = " " + bodyWriter[i]
}
result = append(result, bodyWriter...)
Expand Down
3 changes: 1 addition & 2 deletions internal/tlcodegen/type_rw_struct_php.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func (trw *TypeRWStruct) phpGetFieldArgsTree(currentType *TypeRWWrapper, current
tree.CloneValuesFrom((*genericsToTrees)[generic])
return
}
for i, _ := range currentType.origTL[0].TemplateArguments {
for i := range currentType.origTL[0].TemplateArguments {
actualArg := currentType.arguments[i]
actualArgRef := currentTypeRef.Args[i]
if actualArg.isNat {
Expand Down Expand Up @@ -93,7 +93,6 @@ func (trw *TypeRWStruct) phpGetFieldArgsTree(currentType *TypeRWWrapper, current
}
}
}
return
}

func (trw *TypeRWStruct) PhpClassNameReplaced() bool {
Expand Down

0 comments on commit a02a3fa

Please sign in to comment.