decko-commons/decko

View on GitHub
card/lib/card.rb

Summary

Maintainability
A
0 mins
Test Coverage
A
100%

Variable Cache used in void context.
Open

  Card::Cache # trigger autoload
Severity: Minor
Found in card/lib/card.rb by rubocop

This cop checks for operators, variables and literals used in void context.

Example:

# bad

def some_method
  some_num * 10
  do_something
end

Example:

# bad

def some_method(some_var)
  some_var
  do_something
end

Example:

# good

def some_method
  do_something
  some_num * 10
end

Example:

# good

def some_method(some_var)
  do_something
  some_var
end

Empty line detected around arguments.
Open


    :comment,      # TODO: refactor in favor of card[add], card[drop]
Severity: Minor
Found in card/lib/card.rb by rubocop

This cops checks if empty lines exist around the arguments of a method invocation.

Example:

# bad
do_something(
  foo

)

process(bar,

        baz: qux,
        thud: fred)

some_method(

  [1,2,3],
  x: y
)

# good
do_something(
  foo
)

process(bar,
        baz: qux,
        thud: fred)

some_method(
  [1,2,3],
  x: y
)

There are no issues that match your filters.

Category
Status