inertia186/radiator

View on GitHub
lib/radiator/mixins/acts_as_wallet.rb

Summary

Maintainability
A
0 mins
Test Coverage

Method has too many lines. [11/10]
Open

      def claim_reward_balance(options)
        reward_steem = options[:reward_steem] || '0.000 STEEM'
        reward_sbd = options[:reward_sbd] || '0.000 SBD'
        reward_vests = options[:reward_vests] || '0.000000 VESTS'
        

This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.

Line is too long. [106/80]
Open

      #     steem = Radiator::Chain.new(chain: :steem, account_name: 'your account name', wif: 'your wif')

Line is too long. [113/80]
Open

      #     steem = Radiator::Chain.new(chain: :steem, account_name: 'your account name', wif: 'your active wif')

Trailing whitespace detected.
Open

        

Trailing whitespace detected.
Open

      

Avoid single-line method definitions.
Open

      def transfer!(options = {}); transfer(options).broadcast!(true); end

This cop checks for single-line method definitions that contain a body. It will accept single-line methods with no body.

Example:

# bad
def some_method; body end
def link_to(url); {:name => url}; end
def @table.columns; super; end

# good
def no_op; end
def self.resource_class=(klass); end
def @table.columns; end

Line is too long. [98/80]
Open

      # @option options [String] :reward_steem The amount of STEEM to claim, like: `100.000 STEEM`

Line is too long. [92/80]
Open

      # @option options [String] :reward_sbd The amount of SBD to claim, like: `100.000 SBD`

Line is too long. [101/80]
Open

      # @option options [String] :reward_vests The amount of VESTS to claim, like: `100.000000 VESTS`

Trailing whitespace detected.
Open

        

Trailing whitespace detected.
Open

      

Line is too long. [91/80]
Open

      #     steem.transfer(amount: '1.000 SBD', to: 'account name', memo: 'this is a memo')

Line is too long. [92/80]
Open

      #     steem.transfer!(amount: '1.000 SBD', to: 'account name', memo: 'this is a memo')

Trailing whitespace detected.
Open

      

Line is too long. [106/80]
Open

      #     steem = Radiator::Chain.new(chain: :steem, account_name: 'your account name', wif: 'your wif')

Trailing whitespace detected.
Open

        

Line is too long. [106/80]
Open

      #     steem = Radiator::Chain.new(chain: :steem, account_name: 'your account name', wif: 'your wif')

Avoid single-line method definitions.
Open

      def claim_reward_balance!(permlink); claim_reward_balance(permlink).broadcast!(true); end

This cop checks for single-line method definitions that contain a body. It will accept single-line methods with no body.

Example:

# bad
def some_method; body end
def link_to(url); {:name => url}; end
def @table.columns; super; end

# good
def no_op; end
def self.resource_class=(klass); end
def @table.columns; end

Missing top-level module documentation comment.
Open

    module ActsAsWallet

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. [86/80]
Open

      # @option options [String] :amount The amount to transfer, like: `100.000 STEEM`

Line is too long. [95/80]
Open

      def claim_reward_balance!(permlink); claim_reward_balance(permlink).broadcast!(true); end

There are no issues that match your filters.

Category
Status