lib/ruby3_backward_compatibility/compatibility/all.rb in ruby3-backward-compatibility-0.1.3 vs lib/ruby3_backward_compatibility/compatibility/all.rb in ruby3-backward-compatibility-0.2.0
- old
+ new
@@ -1,7 +1,8 @@
require 'ruby3_backward_compatibility'
-require 'ruby3_backward_compatibility/compatibility/erb'
+require 'ruby3_backward_compatibility/compatibility/erb' if defined?(ERB)
+require 'ruby3_backward_compatibility/compatibility/i18n' if defined?(I18n)
require 'ruby3_backward_compatibility/compatibility/object'
-require 'ruby3_backward_compatibility/compatibility/psych'
+require 'ruby3_backward_compatibility/compatibility/psych' if defined?(Psych)
require 'ruby3_backward_compatibility/compatibility/string'
-require 'ruby3_backward_compatibility/compatibility/uri'
+require 'ruby3_backward_compatibility/compatibility/uri' if defined?(URI)