lib/alba.rb in alba-2.3.0 vs lib/alba.rb in alba-2.4.0
- old
+ new
@@ -64,26 +64,26 @@
# Enable inference for key and resource name
#
# @param with [Symbol, Class, Module] inflector
# When it's a Symbol, it sets inflector with given name
# When it's a Class or a Module, it sets given object to inflector
- # @deprecated Use {#inflector=} instead
+ # @deprecated Use {.inflector=} instead
def enable_inference!(with:)
Alba::Deprecation.warn('Alba.enable_inference! is deprecated. Use `Alba.inflector=` instead.')
@inflector = inflector_from(with)
@inferring = true
end
# Disable inference for key and resource name
#
- # @deprecated Use {#inflector=} instead
+ # @deprecated Use {.inflector=} instead
def disable_inference!
Alba::Deprecation.warn('Alba.disable_inference! is deprecated. Use `Alba.inflector = nil` instead.')
@inferring = false
@inflector = nil
end
- # @deprecated Use {#inflector} instead
+ # @deprecated Use {.inflector} instead
# @return [Boolean] whether inference is enabled or not
def inferring
Alba::Deprecation.warn('Alba.inferring is deprecated. Use `Alba.inflector` instead.')
@inferring
end