diff options
author | Tim Smith <tsmith84@gmail.com> | 2020-11-08 17:32:34 -0800 |
---|---|---|
committer | Tim Smith <tsmith84@gmail.com> | 2020-11-08 17:41:45 -0800 |
commit | 2d5aeee1c2eae4c46f7053b38560efc8d0b4a7b6 (patch) | |
tree | 113ab23df58a52925a8cd1db74f2f9b3cc6768ad /lib/chef/provider/package/freebsd/pkgng.rb | |
parent | d6ffd5b44a04ff32e9049ed8c04bf4dad38e5b7e (diff) | |
download | chef-2d5aeee1c2eae4c46f7053b38560efc8d0b4a7b6.tar.gz |
Don't uses regexes in splits when we don't need tono_regex_in_split
We can do this with strings alone
Signed-off-by: Tim Smith <tsmith@chef.io>
Diffstat (limited to 'lib/chef/provider/package/freebsd/pkgng.rb')
-rw-r--r-- | lib/chef/provider/package/freebsd/pkgng.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/provider/package/freebsd/pkgng.rb b/lib/chef/provider/package/freebsd/pkgng.rb index 48fc7a0dd5..87acb3a830 100644 --- a/lib/chef/provider/package/freebsd/pkgng.rb +++ b/lib/chef/provider/package/freebsd/pkgng.rb @@ -62,7 +62,7 @@ class Chef end pkg_query = shell_out!("pkg", "rquery", options, "%v", new_resource.package_name, env: nil) - pkg_query.exitstatus == 0 ? pkg_query.stdout.strip.split(/\n/).last : nil + pkg_query.exitstatus == 0 ? pkg_query.stdout.strip.split('\n').last : nil end def repo_regex |