instance method stringify_key

Ruby on Rails edge

Since edge Private — implementation detail, not part of the public API

Signature

stringify_key(key)

Flash keys are Symbols at nearly every call site. Symbol#name returns the interned frozen string where Symbol#to_s would allocate a new one.

Parameters

key req
Source
# File actionpack/lib/action_dispatch/middleware/flash.rb, line 310
        def stringify_key(key)
          key.is_a?(Symbol) ? key.name : key.to_s
        end

Defined in actionpack/lib/action_dispatch/middleware/flash.rb line 310 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActionDispatch::Flash::FlashHash

Type at least 2 characters to search.

Use the arrow keys to navigate results, Enter to open one, Escape to close.

Keyboard shortcuts

/
Focus search
⌘K / Ctrl-K
Command palette
?
This help
Esc
Close