hacken-in/hacken-in

View on GitHub
app/helpers/application_helper.rb

Summary

Maintainability
A
0 mins
Test Coverage

Complex method ApplicationHelper#collect_links (23.1)
Open

  def collect_links(item)
    links = []

    if item.url.present?
      links << { url: item.url,
Severity: Minor
Found in app/helpers/application_helper.rb by flog

Flog calculates the ABC score for methods. The ABC score is based on assignments, branches (method calls), and conditions.

You can read more about ABC metrics or the flog tool

Complex method ApplicationHelper#avatar_for_user (22.5)
Open

  def avatar_for_user(user, size = 16, class_name = nil)
    if user.gravatar_email.present?
      gravatar_image_tag(user.gravatar_email, title: user.nickname, alt: user.nickname, class: class_name, gravatar: { default: :identicon, size: size })
    elsif user.email.present?
      gravatar_image_tag(user.email, title: user.nickname, alt: user.nickname, class: class_name, gravatar: { default: :identicon, size: size })
Severity: Minor
Found in app/helpers/application_helper.rb by flog

Flog calculates the ABC score for methods. The ABC score is based on assignments, branches (method calls), and conditions.

You can read more about ABC metrics or the flog tool

There are no issues that match your filters.

Category
Status