Method: Hanami::Utils::LoadPaths#freeze

Defined in:
lib/hanami/utils/load_paths.rb

#freezeObject

It freezes the object by preventing further modifications.

Examples:

require 'hanami/utils/load_paths'

paths = Hanami::Utils::LoadPaths.new
paths.freeze

paths.frozen?  # => true

paths.push '.' # => RuntimeError

See Also:

Since:

  • 0.2.0



137
138
139
140
# File 'lib/hanami/utils/load_paths.rb', line 137

def freeze
  super
  @paths.freeze
end