decko-commons/decko

View on GitHub
cardname/lib/cardname.rb

Summary

Maintainability
A
0 mins
Test Coverage
A
98%

Method Cardname#key is defined at both cardname/lib/cardname.rb:42 and cardname/lib/cardname.rb:74.
Open

  def key
Severity: Minor
Found in cardname/lib/cardname.rb by rubocop

This cop checks for duplicated instance (or singleton) method definitions.

Example:

# bad

def duplicated
  1
end

def duplicated
  2
end

Example:

# bad

def duplicated
  1
end

alias duplicated other_duplicated

Example:

# good

def duplicated
  1
end

def other_duplicated
  2
end

Freeze mutable objects assigned to constants.
Open

  OK4KEY_RE = '\p{Word}\*'
Severity: Minor
Found in cardname/lib/cardname.rb by rubocop

This cop checks whether some constant value isn't a mutable literal (e.g. array or hash).

Example:

# bad
CONST = [1, 2, 3]

# good
CONST = [1, 2, 3].freeze

There are no issues that match your filters.

Category
Status