class Calligraphy::Put

Responsible for replacing the `Get` response entity of the resource.

Public Instance Methods

execute() click to toggle source

Executes the WebDAV request for a particular resource.

# File lib/calligraphy/web_dav_request/put.rb, line 7
def execute
  return :locked if @resource.locked_to_user? @headers
  return :method_not_allowed if @resource.collection?

  @resource.write

  [:created, @resource.contents]
end