Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6a7b52a

Browse files
author
Andrew Crump
committed
FC002: Avoid unnecessary string interpolation.
1 parent 0f4031c commit 6a7b52a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

providers/pip.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,8 @@ def remove_package(name, version, timeout)
158158
def pip_cmd(nr)
159159
if (nr.respond_to?("virtualenv") && nr.virtualenv)
160160
::File.join(nr.virtualenv,'/bin/pip')
161-
elsif "#{node['python']['install_method']}".eql?("source")
162-
::File.join("#{node['python']['prefix_dir']}","/bin/pip")
161+
elsif node['python']['install_method'].eql?("source")
162+
::File.join(node['python']['prefix_dir'],"/bin/pip")
163163
else
164164
'pip'
165165
end

providers/virtualenv.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ def load_current_resource
5454
end
5555

5656
def virtualenv_cmd()
57-
if "#{node['python']['install_method']}".eql?("source")
58-
::File.join("#{node['python']['prefix_dir']}","/bin/virtualenv")
57+
if node['python']['install_method'].eql?("source")
58+
::File.join(node['python']['prefix_dir'],"/bin/virtualenv")
5959
else
6060
"virtualenv"
6161
end

0 commit comments

Comments
 (0)