Module: Honesty::InstanceMethods

Defined in:
lib/honesty.rb

Instance Method Summary collapse

Instance Method Details

#fact(*params) ⇒ Object



18
19
20
21
22
23
24
# File 'lib/honesty.rb', line 18

def fact(*params)
   	if params.length == 3
 		self.facts.create(:context => params[0], :agent => params[1], :action => params[2])
 	elsif params.length == 2
 		self.facts.create(:context => self.class.name, :agent => params[0], :action => params[1])
	end
end