diff --git a/lib/puppet/rails/param_name.rb b/lib/puppet/rails/param_name.rb
index <HASH>..<HASH> 100644
--- a/lib/puppet/rails/param_name.rb
+++ b/lib/puppet/rails/param_name.rb
@@ -9,7 +9,7 @@ class Puppet::Rails::ParamName < ActiveRecord::Base
         hash = {}
         hash[:name] = self.name.to_sym
         hash[:source] = source
-        hash[:value] = resource.param_values.find(:all, :conditions => [ "param_name_id = ?", self]).collect { |v| v.value }
+        hash[:value] = resource.param_values.find(:all, :conditions => [ "param_name_id = ?", self.id]).collect { |v| v.value }
         if hash[:value].length == 1
             hash[:value] = hash[:value].shift
         elsif hash[:value].empty?
Fixed #<I> by applying patch by vvidic.