# Make a hash that unsets Bundle's environment variables.
# We'll use this environment when we launch Bundle commands in the API
# server. Otherwise, those commands will try to use Workbench's gems, etc.
- @@APIENV = ENV.map { |(key, val)| (key =~ /^BUNDLE_/) ? [key, nil] : nil }.
- compact.to_h
+ @@APIENV = Hash[ENV.map { |key, val|
+ (key =~ /^BUNDLE_/) ? [key, nil] : nil
+ }.compact]
def _system(*cmd)
if not system(@@APIENV, *cmd)