From c236212600ff3094fea3b138ee0ff98652d94345 Mon Sep 17 00:00:00 2001 From: David Rodriguez Date: Fri, 26 Jan 2024 10:41:00 +0100 Subject: [PATCH] [rubygems/rubygems] Use deprecation helper for deprecation warning https://github.com/rubygems/rubygems/commit/d1963bf1a6 --- lib/bundler/definition.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/bundler/definition.rb b/lib/bundler/definition.rb index 32a7089925..c8faf77b3b 100644 --- a/lib/bundler/definition.rb +++ b/lib/bundler/definition.rb @@ -334,7 +334,9 @@ module Bundler "Instead, instantiate a new definition passing `#{target_lockfile}`, and call `lock` without a file argument on that definition" end - warn "Passing a file to `Definition#lock` is deprecated. #{suggestion}" + msg = "`Definition#lock` was passed a target file argument. #{suggestion}" + + Bundler::SharedHelpers.major_deprecation 2, msg end write_lock(target_lockfile, preserve_unknown_sections)