Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Removed call to JSON.parse in Collection.create that causes a parse exception #6

Closed
wants to merge 1 commit into from

4 participants

Keiron McCammon Marshall Sontag Ali Chris McGuire
Keiron McCammon

Removed call to JSON.parse in create as according to the API docs (https://labs.aweber.com/docs/reference/1.0#subscribers) the POST just returns 201 CREATED with a link to the newly created subscriber appearing in the Location header.

Keiron McCammon kmccammon Removed call to JSON.parse in create as according to the API docs (ht…
…tps://labs.aweber.com/docs/reference/1.0#subscribers) the POST just returns 201 CREATED with a link to the newly created subscriber appearing in the Location header.
2f01f2d
Marshall Sontag

Thanks for the fix commit. This was frustrating me too.

Ali
Najaf commented

Any chance of getting this guy merged?

Chris McGuire
Collaborator

Thanks for the report. Your changes were included in 4e087c5.

Chris McGuire
Collaborator

This change was deployed in gem version 1.4.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Jan 05, 2012
Keiron McCammon kmccammon Removed call to JSON.parse in create as according to the API docs (ht…
…tps://labs.aweber.com/docs/reference/1.0#subscribers) the POST just returns 201 CREATED with a link to the newly created subscriber appearing in the Location header.
2f01f2d
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 0 additions and 1 deletion. Show diff stats Hide diff stats

  1. +0 1  lib/aweber/collection.rb
1  lib/aweber/collection.rb
@@ -65,7 +65,6 @@ def create(attrs={})
65 65
66 66 return false unless response.is_a? Net::HTTPCreated
67 67
68   - response = JSON.parse(response.body)
69 68 resource = get(response["location"]).merge(:parent => self)
70 69 resource = @klass.new(client, resource)
71 70

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.