Permalink
Browse files

Explicitly make post xml

  • Loading branch information...
alexbartlow committed Jan 9, 2012
1 parent 1e277bf commit ead64c6923cf37738e66ced335acb6e091b94120
Showing with 2 additions and 28 deletions.
  1. +2 −28 lib/linked_in/api/update_methods.rb
@@ -1,32 +1,13 @@
require 'builder'
module LinkedIn
module Api
-
module UpdateMethods
-
def add_share(share)
path = "/people/~/shares"
defaults = {:visibility => {:code => "anyone"}}
post(path, defaults.merge(share).to_json, "Content-Type" => "application/json")
end
- # def share(options={})
- # path = "/people/~/shares"
- # defaults = { :visability => 'anyone' }
- # post(path, share_to_xml(defaults.merge(options)))
- # end
- #
- # def update_comment(network_key, comment)
- # path = "/people/~/network/updates/key=#{network_key}/update-comments"
- # post(path, comment_to_xml(comment))
- # end
- #
- # def update_network(message)
- # path = "/people/~/person-activities"
- # post(path, network_update_to_xml(message))
- # end
- #
- #
def send_message(subject, body, *recipient_ids)
path = "/people/~/mailbox"
@@ -46,16 +27,9 @@ def send_message(subject, body, *recipient_ids)
xml.text! body
end
end
- post(path, xml.target!).code
+ post(path, xml.target!, 'Content-Type' => "application/xml").code
end
- #
- # def clear_status
- # path = "/people/~/current-status"
- # delete(path).code
- # end
- #
-
end
-
end
end
+

0 comments on commit ead64c6

Please sign in to comment.