lib/keylime/credential.rb in keylime-0.2.1 vs lib/keylime/credential.rb in keylime-0.3.0

- old
+ new

@@ -4,11 +4,11 @@ module Keylime ENABLED = begin require 'keychain' true rescue LoadError - raise if RUBY_PLATFORM =~ /darwin/ + raise if RUBY_PLATFORM.include?('darwin') false end ## # Easy wrapper around getting and setting secrets @@ -131,10 +131,10 @@ def file @file ||= File.expand_path @keychain end def stringify(fields) - fields.map { |k, v| [k.to_s, v] }.to_h + fields.transform_keys(&:to_s) end end ## # Object for stub file keychain