Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: move object directive logic to object function #3308

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

WingT
Copy link

@WingT WingT commented Sep 28, 2024

Change-Id: I6d1789756f7990666f4a0e01761a94816f0fc996

Describe your PR and link to any relevant issues.
#3306
I have:

  • Added tests covering the bug / feature (see testing)
  • Updated any relevant documentation (see docs)

Change-Id: I6d1789756f7990666f4a0e01761a94816f0fc996
}
for _, dir := range obj.Directives {
if dir.IsLocation(ast.LocationInputObject) {
dirs = append(dirs, dir)
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why duplicate directives on LocationInputObject?

@StevenACoffman
Copy link
Collaborator

StevenACoffman commented Sep 28, 2024

I appreciate your working on this, but I actually really prefer to move logic out of the template files and back into library functions in standard Go files. Template logic is harder to maintain, as linters and other unit testing is much harder to deal with inside of templates.

I think your intent of making things simpler and more convenient is a good one though.

@coveralls
Copy link

Coverage Status

coverage: 58.865% (-0.02%) from 58.882%
when pulling 9569785 on WingT:master
into 7177055 on 99designs:master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants