def data_bag_config_for(environment, source)
      data_bag_item = encrypted_data_bag_for(environment, DATA_BAG)

      if data_bag_item.has_key?(source)
        data_bag_item[source]
      elsif DATA_BAG == source
        data_bag_item
      else
        {}
      end
    end
def data_bag_config_for(environment, source)
      data_bag_item = encrypted_data_bag_for(environment, DATA_BAG)

      if data_bag_item.has_key?(source)
        data_bag_item[source]
      elsif DATA_BAG == source
        data_bag_item
      else
        {}
      end
    end
Loads the encrypted data bag item and returns credentials for the
 environment or for a default key.

 @param [String] environment
   The environment

 @param [String] source
   The deployment source to load configuration for

 @return [Chef::DataBagItem]
   The data bag item