Module: CommandKit::BugReport::ClassMethods

Defined in:
lib/command_kit/bug_report.rb

Overview

Defines class-level methods.

Since:

  • 0.4.0

Instance Method Summary collapse

Instance Method Details

#bug_report_url(new_url = nil) ⇒ String?

Gets or sets the bug report URL.

Examples:

bug_report_url 'https://github.com/user/repo/issues/new'

Parameters:

  • new_url (String, nil) (defaults to: nil)

    The new bug report URL.

Returns:

  • (String, nil)

    The bug report URL.

Since:

  • 0.4.0



57
58
59
60
61
62
63
64
65
# File 'lib/command_kit/bug_report.rb', line 57

def bug_report_url(new_url=nil)
  if new_url
    @bug_report_url = new_url
  else
    @bug_report_url || if superclass.kind_of?(ClassMethods)
                         superclass.bug_report_url
                       end
  end
end