@@ -181,10 +181,10 @@ def log_debug(*args, level: :debug, **options, &block)
181181 end
182182
183183 ##
184- # @overload log_depth(options, &block)
184+ # @overload log_depth(depth: 1, ** options, &block)
185185 # Increase depth around a method invocation
186+ # @param [Integer] :depth Additional recursion depth
186187 # @param [Hash{Symbol}] options (@options || {})
187- # @option options [Integer] :depth Additional recursion depth
188188 # @option options [Logger, #<<] :logger
189189 # @yield
190190 # Yields with no arguments
@@ -194,8 +194,8 @@ def log_debug(*args, level: :debug, **options, &block)
194194 # @overload log_depth
195195 # # Return the current log depth
196196 # @return [Integer]
197- def log_depth ( **options , &block )
198- self . logger ( **options ) . log_depth ( &block )
197+ def log_depth ( depth : 1 , **options , &block )
198+ self . logger ( **options ) . log_depth ( depth : depth , &block )
199199 end
200200
201201 private
@@ -244,7 +244,7 @@ def log_statistics
244244 end
245245
246246 ##
247- # @overload log_depth(options, &block)
247+ # @overload log_depth(depth: 1, ** options, &block)
248248 # Increase depth around a method invocation
249249 # @param [Integer] depth (1) recursion depth
250250 # @param [Hash{Symbol}] options (@options || {})
0 commit comments