layout 'site'
require 'xml/libxml'
+ skip_before_filter :verify_authenticity_token, :except => [:list]
before_filter :authorize_web, :only => [:list]
before_filter :set_locale, :only => [:list]
before_filter :authorize, :only => [:create, :update, :delete, :upload, :include, :close]
created << elt.to_xml_node
else
# get the previous version from the element history
- prev_elt = elt.class.where(:id => elt.id, :version => elt.version).first
+ prev_elt = elt.class.find([elt.id, elt.version])
unless elt.visible
# if the element isn't visible then it must have been deleted, so
# output the *previous* XML