Skip to content

Commit cd31b16

Browse files
authored
Merge pull request rails#51731 from Shopify/improve-rails-helpers-descriptions
Improve Rails console helper methods' descriptions
2 parents 7ad4d8f + 53a0b8c commit cd31b16

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

railties/lib/rails/commands/console/irb_console.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ class RailsHelperBase < IRB::HelperMethod::Base
1010
end
1111

1212
class ControllerHelper < RailsHelperBase
13-
description "Gets the helper methods available to the controller."
13+
description "Gets helper methods available to ApplicationController."
1414

1515
# This method assumes an +ApplicationController+ exists, and that it extends ActionController::Base.
1616
def execute
@@ -19,7 +19,7 @@ def execute
1919
end
2020

2121
class ControllerInstance < RailsHelperBase
22-
description "Gets a new instance of a controller object."
22+
description "Gets a new instance of ApplicationController."
2323

2424
# This method assumes an +ApplicationController+ exists, and that it extends ActionController::Base.
2525
def execute
@@ -28,7 +28,7 @@ def execute
2828
end
2929

3030
class NewSession < RailsHelperBase
31-
description "Create a new session. If a block is given, the new session will be yielded to the block before being returned."
31+
description "[Deprecated] Please use `app(true)` instead."
3232

3333
def execute(*)
3434
app = Rails.application
@@ -43,7 +43,7 @@ def execute(*)
4343
end
4444

4545
class AppInstance < NewSession
46-
description "Reference the global 'app' instance, created on demand. To recreate the instance, pass a non-false value as the parameter."
46+
description "Creates a new ActionDispatch::Integration::Session and memoizes it. Use `app(true)` to create a new instance."
4747

4848
def execute(create = false)
4949
@app_integration_instance = nil if create
@@ -55,7 +55,7 @@ class Reloader < IRB::Command::Base
5555
include ConsoleMethods
5656

5757
category "Rails console"
58-
description "Reloads the environment."
58+
description "Reloads the Rails application."
5959

6060
def execute(*)
6161
puts "Reloading..."

0 commit comments

Comments
 (0)