Graphql/AuthorizeTypes: Add offenses for empty authorize statements
What does this MR do and why?
Describe in detail what your merge request does and why.
An authorize
statement with no arguments is the same as not having an
authorize statement at all. So, we should flag an offense if authorize
does not have any arguments.
Bad
This currently does not result in any offenses.
module Types
class SomeType < BaseType
authorize
end
end
Good
module Types
class SomeType < BaseType
authorize :read_code
end
end
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Brian Williams