Skip to content

Commit bf3fef2

Browse files
fixup! feat: add two-factor method registration and base model module
1 parent 941630e commit bf3fef2

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

lib/devise.rb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -462,10 +462,12 @@ def self.add_module(module_name, options = {})
462462
#
463463
# +name+ - String representing the name of the 2FA method. This will be used to identify it.
464464
# +model+ - String representing the load path to a custom *model* for this 2FA method (to autoload.)
465-
# +route+ - Symbol representing the named *route* helper for this 2FA method.
466465
# +strategy+ - Symbol representing if this module got a custom *strategy*.
467-
#
468-
# The :route option accepts a boolean, Symbol, or Hash. When true, the route name defaults to the method name.
466+
# +route+ - Generates extension-specific routes and URL helpers (e.g., credential management
467+
# endpoints). This is separate from the core challenge/create routes that Devise
468+
# generates automatically from +two_factor_methods+. Accepts true (defaults route
469+
# name to the method name), a Symbol, or a Hash. Works the same as the +:route+
470+
# option in +add_module+.
469471
#
470472
# == Examples:
471473
#

0 commit comments

Comments
 (0)