diff --git a/libraries/helpers.rb b/libraries/helpers.rb index 25a3051..f6dd544 100644 --- a/libraries/helpers.rb +++ b/libraries/helpers.rb @@ -33,7 +33,7 @@ module ChefVaultCookbook # @param [String] bag Name of the data bag to load from. # @param [String] id Identifier of the data bag item to load. def chef_vault_item(bag, id) - if ChefVault::Item.vault?(bag, id) + if Chef::DataBag.load(bag).key?("#{id}_keys") ChefVault::Item.load(bag, id) elsif node['chef-vault']['databag_fallback'] Chef::DataBagItem.load(bag, id)