Skip to content

Commit 73be078

Browse files
Merge pull request #3240 from donoghuc/GH-3236
(GH-3236) Only set ruby env vars on local transport when they exist
2 parents 6d662cb + 8080be7 commit 73be078

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/bolt/transport/local/connection.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,9 @@ def execute(command)
7373
# Only do this if bundled-ruby is set to false, not nil
7474
ruby_env_vars = if target.transport_config['bundled-ruby'] == false
7575
RUBY_ENV_VARS.each_with_object({}) do |e, acc|
76-
acc[e] = ENV["BOLT_ORIG_#{e}"] if ENV["BOLT_ORIG_#{e}"]
76+
if ENV["BOLT_ORIG_#{e}"] && !ENV["BOLT_ORIG_#{e}"].empty?
77+
acc[e] = ENV["BOLT_ORIG_#{e}"]
78+
end
7779
end
7880
end
7981

0 commit comments

Comments
 (0)