wycleffsean/haypub

View on GitHub
lib/payhub/schedule/weekly.rb

Summary

Maintainability
A
0 mins
Test Coverage

Extra empty line detected at module body end.
Open


  end
Severity: Minor
Found in lib/payhub/schedule/weekly.rb by rubocop

This cops checks if empty lines around the bodies of modules match the configuration.

Example: EnforcedStyle: empty_lines

# good

module Foo

  def bar
    # ...
  end

end

Example: EnforcedStyle: emptylinesexcept_namespace

# good

module Foo
  module Bar

    # ...

  end
end

Example: EnforcedStyle: emptylinesspecial

# good
module Foo

  def bar; end

end

Example: EnforcedStyle: noemptylines (default)

# good

module Foo
  def bar
    # ...
  end
end

Missing top-level class documentation comment.
Open

    class Weekly
Severity: Minor
Found in lib/payhub/schedule/weekly.rb by rubocop

This cop checks for missing top-level documentation of classes and modules. Classes with no body are exempt from the check and so are namespace modules - modules that have nothing in their bodies except classes, other modules, or constant definitions.

The documentation requirement is annulled if the class or module has a "#:nodoc:" comment next to it. Likewise, "#:nodoc: all" does the same for all its children.

Example:

# bad
class Person
  # ...
end

# good
# Description/Explanation of Person class
class Person
  # ...
end

Line is too long. [83/80]
Open

      # @option opts [Integer] :bill_generation_interval The interval between bills
Severity: Minor
Found in lib/payhub/schedule/weekly.rb by rubocop

Prefer Object#is_a? over Object#kind_of?.
Open

        if days.last.kind_of? Hash
Severity: Minor
Found in lib/payhub/schedule/weekly.rb by rubocop

This cop enforces consistent use of Object#is_a? or Object#kind_of?.

Example: EnforcedStyle: is_a? (default)

# bad
var.kind_of?(Date)
var.kind_of?(Integer)

# good
var.is_a?(Date)
var.is_a?(Integer)

Example: EnforcedStyle: kind_of?

# bad
var.is_a?(Time)
var.is_a?(String)

# good
var.kind_of?(Time)
var.kind_of?(String)

There are no issues that match your filters.

Category
Status