Skip to content

Instantly share code, notes, and snippets.

@wjlroe
Created May 21, 2011 15:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wjlroe/984633 to your computer and use it in GitHub Desktop.
Save wjlroe/984633 to your computer and use it in GitHub Desktop.
to_xml - is there a better way?
class Room < ActiveRecord::Base
def full
false
end
def to_xml(options = {})
options[:methods] = [:full]
super(options)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment