app/controllers/admin/application_controller.rb
TODO found Open
Open
# TODO Add authentication logic here.
- Exclude checks
Annotation keywords like TODO
should be all upper case, followed by a colon, and a space, then a note describing the problem. Open
Open
# TODO Add authentication logic here.
- Read upRead up
- Exclude checks
This cop checks that comment annotation keywords are written according to guidelines.
Example:
# bad
# TODO make better
# good
# TODO: make better
# bad
# TODO:make better
# good
# TODO: make better
# bad
# fixme: does not work
# good
# FIXME: does not work
# bad
# Optimize does not work
# good
# OPTIMIZE: does not work
Use nested module/class definitions instead of compact style. Open
Open
class Admin::ApplicationController < Administrate::ApplicationController
- Read upRead up
- Exclude checks
This cop checks the style of children definitions at classes and modules. Basically there are two different styles:
Example: EnforcedStyle: nested (default)
# good
# have each child on its own line
class Foo
class Bar
end
end
Example: EnforcedStyle: compact
# good
# combine definitions as much as possible
class Foo::Bar
end
The compact style is only forced for classes/modules with one child.