chore: fix lint errors #185
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request refactors the codebase to replace the use of
interface{}with the more modernanytype throughout the project, improving readability and aligning with Go's latest conventions. Additionally, it updates function signatures, type declarations, and method implementations to useany, and makes minor improvements to comments and code clarity. There are also small adjustments to linter configuration and union type filtering logic.Type modernization and code consistency
interface{}withanyin function signatures, method parameters, type declarations, and map definitions across files such asgraphql.go,query.go,scalar.go, andsubscription.go. This includes changes to decoding, unmarshalling, logging, and GraphQL variable handling. [1] [2] [3] [4]map[string]interface{}tomap[string]anyfor GraphQL variables and connection parameters throughout the codebase, including public APIs and internal logic. [1] [2]Subscription and logging improvements
anyfor message and argument types, improving code clarity and consistency. [1] [2] [3] [4]SubscriptionClientand related methods to useanyin connection parameters, loggers, and handler functions. [1] [2] [3]GraphQL decoding and query construction
graphql.goto useanyinstead ofinterface{}for improved type safety and readability. [1] [2] [3] [4]anyfor variables and struct values, and adjusted related helper functions. [1] [2] [3] [4] [5] [6] [7]Minor improvements and fixes
filterUnionFieldsByTypeNameto simplify conditional checks and code structure.subscription.goto improve documentation. [1] [2]Linter configuration
funlenlinter configuration in.golangci.ymlto accommodate larger functions.