lib/rbs/collection/config/lockfile_generator.rb in rbs-3.0.0 vs lib/rbs/collection/config/lockfile_generator.rb in rbs-3.0.1

- old
+ new

@@ -137,15 +137,14 @@ end private def assign_stdlib(name:, from_gem:) return if lockfile.gems.key?(name) - if name == 'rubygems' - if from_gem - RBS.logger.warn "`rubygems` has been moved to core library, so it is always loaded. Remove explicit loading `rubygems` from `#{from_gem}`" - else - RBS.logger.warn '`rubygems` has been moved to core library, so it is always loaded. Remove explicit loading `rubygems`' - end + case name + when 'rubygems', 'set' + msg = "`#{name}` has been moved to core library, so it is always loaded. Remove explicit loading `#{name}`" + msg << " from `#{from_gem}`" if from_gem + RBS.logger.warn msg return end source = Sources::Stdlib.instance