lib/amee/profile_item.rb in Floppy-amee-0.4.25 vs lib/amee/profile_item.rb in Floppy-amee-0.4.26
- old
+ new
@@ -101,12 +101,13 @@
def self.create(profile, data_item_uid, options = {})
# Send data to path
options.merge! :dataItemUid => data_item_uid
response = profile.connection.post(profile.full_path, options)
- return Item.parse(profile.connection, response)
- rescue
- raise AMEE::BadData.new("Couldn't create ProfileItem. Check that your information is correct.")
+ category = Category.parse(profile.connection, response)
+ return category.item(options)
+ #rescue
+ # raise AMEE::BadData.new("Couldn't create ProfileItem. Check that your information is correct.")
end
def update(options = {})
connection.put(full_path, options)
return Item.parse(connection, response)