payola-payments 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ODA0NTAxNDgzNTJmNjBlNThmNGI3YjkzOThhMTEwODMzOTM2OTgzMg==
4
+ YjVkNzEyNTE1ZDMzNDgwMmJkOWNiYWQ4MTgyMzNiNmFjOTcyMGFkMA==
5
5
  data.tar.gz: !binary |-
6
- NjVhZjQ4MjJjZTc2MDJiNjkxYjc0MzY2MTFlMTRiZDE2YmQxMTgyOA==
6
+ OTAzZjY5MjRkNjEyNzUwNjZiMTQyOWMxNDI5ODE4ZDI1YWFlNzk3Nw==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MDA3NjFiM2E2ZjAyNGNjZDQ1Nzg0MDQwYTY1N2I2YjlkZDA3YmU5MTJhMGQ1
10
- Y2Q3MWM4OTM0YzE0ODNkOTAzYjhjOTU4ZjY1NDk1Y2ZiMjA1ZmQ3ODY5YzQy
11
- YjgxZWM1M2Y4ZmRkMGMzZWQyN2VlODNhYWJjMTU4NDgyMDgyNzQ=
9
+ YjQzOTg1YzNmZTM5MTRkNjIyYTVlNGU2MWYzMjc4NzJjNDA0MWMzNTcxZTlm
10
+ Nzg4OTgxNTBhYTAzMTZlMjRiZmZlMjIyMTI3Y2E0ZDQzMjczOWZjMDNiODcw
11
+ YzIxYzNiODMyNTQzMGU5YmMzMjM3MjNlNjMxOTMwMTcxY2UwODc=
12
12
  data.tar.gz: !binary |-
13
- MGUyMjM5MjZkMGI1MjY2NWFkMDZmNWUyMmY3OWZjYTlkYTZkYWMwMzhjNGJl
14
- MWU3Y2YwYjU4ZTJiYjQwNGI1YmRjOWY0MTExYzAzMmUwMzA3YmRiYjhjMGFl
15
- NDQ3MjM1MWU2YmE3Y2U5YzEzZTgzMGJiMTkyYjRkYzQ3MGUxMTE=
13
+ OTg2YzcxMmJmNGJhNmU1MmVmMGZmMmE5MWQ4MGMyZWMzM2I3MDdjM2ZmODY2
14
+ ZjI0NTc2NTk4ZWU3ZWI4NjM4YzI5MGM3NjliYmY5ODRmNThlNjI4MWMwMzc4
15
+ NDQyOWJlODZjNDBmMmE4ZjU0ODNkZWRjMjMxN2NiNGVhMmFiNzM=
@@ -13,19 +13,20 @@ var PayolaCheckout = {
13
13
  var handler = StripeCheckout.configure({
14
14
  key: options.publishable_key,
15
15
  image: options.product_image_path,
16
- token: function(token) { PayolaCheckout.tokenHandler(token, options) }
17
- });
18
-
19
- handler.open({
16
+ token: function(token) { PayolaCheckout.tokenHandler(token, options) },
20
17
  name: options.name,
21
18
  description: options.description,
22
19
  amount: options.price,
23
20
  panelLabel: options.panel_label,
24
21
  allowRememberMe: options.allow_remember_me,
25
22
  zipCode: options.verify_zip_code,
23
+ billingAddress: options.billing_address,
24
+ shippingAddress: options.shipping_address,
26
25
  currency: options.currency,
27
26
  email: options.email || undefined
28
27
  });
28
+
29
+ handler.open();
29
30
  },
30
31
 
31
32
  tokenHandler: function(token, options) {
@@ -12,12 +12,14 @@ module Payola
12
12
  email: sale.email
13
13
  }, secret_key)
14
14
 
15
- charge = Stripe::Charge.create({
15
+ charge_attributes = {
16
16
  amount: sale.amount,
17
17
  currency: sale.currency,
18
18
  customer: customer.id,
19
19
  description: sale.guid,
20
- }, secret_key)
20
+ }.merge(Payola.additional_charge_attributes.call(sale))
21
+
22
+ charge = Stripe::Charge.create(charge_attributes, secret_key)
21
23
 
22
24
  if charge.respond_to?(:fee)
23
25
  fee = charge.fee
@@ -1,4 +1,6 @@
1
1
  <p>Thank you for buying <%= @product.name %></p>
2
2
  <p>Your transaction ID is: <b><%= @sale.guid %></p>
3
3
  <p><%= link_to "Click here to pick up your product", payola.confirm_url(guid: @sale.guid) %></p>
4
+ <% if Payola.pdf_receipt %>
4
5
  <p>Attached you'll find a PDF receipt for your records.</p>
6
+ <% end %>
@@ -2,6 +2,8 @@ Thanks for buying <%= @product.name %>.
2
2
 
3
3
  Your transaction ID is: <%= @sale.guid %>
4
4
 
5
- Click here to read the book: <%= payola.confirm_url(guid: @sale.guid) %>
5
+ Click here to pick up your product: <%= payola.confirm_url(guid: @sale.guid) %>
6
6
 
7
+ <% if Payola.pdf_receipt %>
7
8
  Attached you'll find a PDF receipt for your records.
9
+ <% end %>
@@ -11,6 +11,8 @@
11
11
  verify_zip_code = local_assigns.fetch :verify_zip_code, false
12
12
  custom_fields = local_assigns.fetch :custom_fields, nil
13
13
  price = local_assigns.fetch :price, sellable.price
14
+ billing_address = local_assigns.fetch :billing_address, false
15
+ shipping_address = local_assigns.fetch :shipping_address, false
14
16
 
15
17
  sale = Payola::Sale.new(product: sellable)
16
18
 
@@ -44,7 +46,9 @@
44
46
  panel_label: panel_label,
45
47
  allow_remember_me: allow_remember_me,
46
48
  email: email,
47
- verify_zip_code: verify_zip_code
49
+ verify_zip_code: verify_zip_code,
50
+ billing_address: billing_address,
51
+ shipping_address: shipping_address
48
52
  }
49
53
 
50
54
  raw_data[:signed_custom_fields] = sale.verifier.generate(custom_fields) if custom_fields
data/lib/payola.rb CHANGED
@@ -15,6 +15,7 @@ module Payola
15
15
  :sellables,
16
16
  :charge_verifier,
17
17
  :default_currency,
18
+ :additional_charge_attributes,
18
19
  :pdf_receipt
19
20
 
20
21
  def configure(&block)
@@ -69,6 +70,7 @@ module Payola
69
70
  self.support_email = 'sales@example.com'
70
71
  self.default_currency = 'usd'
71
72
  self.sellables = {}
73
+ self.additional_charge_attributes = lambda { |sale| { } }
72
74
  self.pdf_receipt = false
73
75
  end
74
76
 
@@ -1,3 +1,3 @@
1
1
  module Payola
2
- VERSION = "1.1.2"
2
+ VERSION = "1.1.3"
3
3
  end
@@ -34085,3 +34085,1247 @@ Completed 400 Bad Request in 2ms (Views: 0.2ms | ActiveRecord: 0.2ms)
34085
34085
   (0.1ms) rollback transaction
34086
34086
   (0.0ms) begin transaction
34087
34087
   (0.1ms) rollback transaction
34088
+  (1.0ms) CREATE TABLE "owners" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) 
34089
+  (1.0ms) CREATE TABLE "payola_affiliates" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "code" varchar(255), "email" varchar(255), "percent" integer, "created_at" datetime, "updated_at" datetime)
34090
+  (1.0ms) CREATE TABLE "payola_coupons" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "code" varchar(255), "percent_off" integer, "created_at" datetime, "updated_at" datetime) 
34091
+  (1.0ms) CREATE TABLE "payola_sales" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "email" varchar(255), "guid" varchar(255), "product_id" integer, "product_type" varchar(255), "created_at" datetime, "updated_at" datetime, "state" varchar(255), "stripe_id" varchar(255), "stripe_token" varchar(255), "card_last4" varchar(255), "card_expiration" date, "card_type" varchar(255), "error" text, "amount" integer, "fee_amount" integer, "coupon_id" integer, "opt_in" boolean, "download_count" integer, "affiliate_id" integer, "customer_address" text, "business_address" text, "stripe_customer_id" varchar(255), "currency" varchar(255), "signed_custom_fields" text, "owner_id" integer, "owner_type" varchar(255))
34092
+  (0.2ms) select sqlite_version(*)
34093
+  (1.1ms) CREATE INDEX "index_payola_sales_on_coupon_id" ON "payola_sales" ("coupon_id")
34094
+  (0.2ms)  SELECT sql
34095
+ FROM sqlite_master
34096
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34097
+ UNION ALL
34098
+ SELECT sql
34099
+ FROM sqlite_temp_master
34100
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34101
+ 
34102
+  (0.8ms) CREATE INDEX "index_payola_sales_on_email" ON "payola_sales" ("email")
34103
+  (0.1ms)  SELECT sql
34104
+ FROM sqlite_master
34105
+ WHERE name='index_payola_sales_on_email' AND type='index'
34106
+ UNION ALL
34107
+ SELECT sql
34108
+ FROM sqlite_temp_master
34109
+ WHERE name='index_payola_sales_on_email' AND type='index'
34110
+ 
34111
+  (0.1ms) SELECT sql
34112
+ FROM sqlite_master
34113
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34114
+ UNION ALL
34115
+ SELECT sql
34116
+ FROM sqlite_temp_master
34117
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34118
+
34119
+  (0.8ms) CREATE INDEX "index_payola_sales_on_guid" ON "payola_sales" ("guid")
34120
+  (0.1ms) SELECT sql
34121
+ FROM sqlite_master
34122
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34123
+ UNION ALL
34124
+ SELECT sql
34125
+ FROM sqlite_temp_master
34126
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34127
+
34128
+  (0.1ms)  SELECT sql
34129
+ FROM sqlite_master
34130
+ WHERE name='index_payola_sales_on_email' AND type='index'
34131
+ UNION ALL
34132
+ SELECT sql
34133
+ FROM sqlite_temp_master
34134
+ WHERE name='index_payola_sales_on_email' AND type='index'
34135
+ 
34136
+  (0.1ms) SELECT sql
34137
+ FROM sqlite_master
34138
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34139
+ UNION ALL
34140
+ SELECT sql
34141
+ FROM sqlite_temp_master
34142
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34143
+
34144
+  (0.8ms) CREATE INDEX "index_payola_sales_on_owner_id_and_owner_type" ON "payola_sales" ("owner_id", "owner_type")
34145
+  (0.1ms) SELECT sql
34146
+ FROM sqlite_master
34147
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34148
+ UNION ALL
34149
+ SELECT sql
34150
+ FROM sqlite_temp_master
34151
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34152
+
34153
+  (0.1ms)  SELECT sql
34154
+ FROM sqlite_master
34155
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34156
+ UNION ALL
34157
+ SELECT sql
34158
+ FROM sqlite_temp_master
34159
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34160
+ 
34161
+  (0.1ms) SELECT sql
34162
+ FROM sqlite_master
34163
+ WHERE name='index_payola_sales_on_email' AND type='index'
34164
+ UNION ALL
34165
+ SELECT sql
34166
+ FROM sqlite_temp_master
34167
+ WHERE name='index_payola_sales_on_email' AND type='index'
34168
+
34169
+  (0.1ms)  SELECT sql
34170
+ FROM sqlite_master
34171
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34172
+ UNION ALL
34173
+ SELECT sql
34174
+ FROM sqlite_temp_master
34175
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34176
+ 
34177
+  (0.8ms) CREATE INDEX "index_payola_sales_on_product" ON "payola_sales" ("product_id", "product_type")
34178
+  (0.1ms)  SELECT sql
34179
+ FROM sqlite_master
34180
+ WHERE name='index_payola_sales_on_product' AND type='index'
34181
+ UNION ALL
34182
+ SELECT sql
34183
+ FROM sqlite_temp_master
34184
+ WHERE name='index_payola_sales_on_product' AND type='index'
34185
+ 
34186
+  (0.1ms) SELECT sql
34187
+ FROM sqlite_master
34188
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34189
+ UNION ALL
34190
+ SELECT sql
34191
+ FROM sqlite_temp_master
34192
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34193
+
34194
+  (0.1ms)  SELECT sql
34195
+ FROM sqlite_master
34196
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34197
+ UNION ALL
34198
+ SELECT sql
34199
+ FROM sqlite_temp_master
34200
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34201
+ 
34202
+  (0.1ms) SELECT sql
34203
+ FROM sqlite_master
34204
+ WHERE name='index_payola_sales_on_email' AND type='index'
34205
+ UNION ALL
34206
+ SELECT sql
34207
+ FROM sqlite_temp_master
34208
+ WHERE name='index_payola_sales_on_email' AND type='index'
34209
+
34210
+  (0.1ms)  SELECT sql
34211
+ FROM sqlite_master
34212
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34213
+ UNION ALL
34214
+ SELECT sql
34215
+ FROM sqlite_temp_master
34216
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34217
+ 
34218
+  (0.9ms) CREATE INDEX "index_payola_sales_on_stripe_customer_id" ON "payola_sales" ("stripe_customer_id")
34219
+  (0.7ms) CREATE TABLE "payola_stripe_webhooks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "stripe_id" varchar(255), "created_at" datetime, "updated_at" datetime) 
34220
+  (0.9ms) CREATE TABLE "payola_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "plan_type" varchar(255), "plan_id" integer, "start" datetime, "status" varchar(255), "owner_type" varchar(255), "owner_id" integer, "stripe_customer_id" varchar(255), "cancel_at_period_end" boolean, "current_period_start" datetime, "current_period_end" datetime, "ended_at" datetime, "trial_start" datetime, "trial_end" datetime, "canceled_at" datetime, "quantity" integer, "stripe_id" varchar(255), "stripe_token" varchar(255), "card_last4" varchar(255), "card_expiration" date, "card_type" varchar(255), "error" text, "state" varchar(255), "email" varchar(255), "created_at" datetime, "updated_at" datetime, "currency" varchar(255), "amount" integer)
34221
+  (0.8ms) CREATE TABLE "products" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "permalink" varchar(255), "price" integer, "created_at" datetime, "updated_at" datetime) 
34222
+  (1.0ms) CREATE TABLE "subscription_plans" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "amount" integer, "interval" varchar(255), "interval_count" integer, "name" varchar(255), "stripe_id" varchar(255), "trial_period_days" integer, "created_at" datetime, "updated_at" datetime)
34223
+  (1.5ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
34224
+  (1.1ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
34225
+  (0.1ms) SELECT version FROM "schema_migrations"
34226
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141106034610')
34227
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141001230848')
34228
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141029140518')
34229
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141105010234')
34230
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141001170138')
34231
+  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20141001203541')
34232
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141002013618')
34233
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141002013701')
34234
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141002203725')
34235
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141017233304')
34236
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141026101628')
34237
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141026144800')
34238
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141029135848')
34239
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141105043439')
34240
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
34241
+  (0.1ms) begin transaction
34242
+  (0.1ms) rollback transaction
34243
+  (0.1ms) begin transaction
34244
+  (0.1ms) rollback transaction
34245
+  (0.0ms) begin transaction
34246
+  (0.1ms) SAVEPOINT active_record_1
34247
+ Payola::StripeWebhook Exists (0.2ms) SELECT 1 AS one FROM "payola_stripe_webhooks" WHERE "payola_stripe_webhooks"."stripe_id" = 'test_id' LIMIT 1
34248
+ SQL (0.5ms) INSERT INTO "payola_stripe_webhooks" ("created_at", "stripe_id", "updated_at") VALUES (?, ?, ?) [["created_at", "2014-11-07 00:20:51.849717"], ["stripe_id", "test_id"], ["updated_at", "2014-11-07 00:20:51.849717"]]
34249
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34250
+ Payola::StripeWebhook Exists (0.1ms) SELECT 1 AS one FROM "payola_stripe_webhooks" WHERE "payola_stripe_webhooks"."stripe_id" = 'test_id' LIMIT 1
34251
+  (0.4ms) rollback transaction
34252
+  (0.0ms) begin transaction
34253
+ Payola::StripeWebhook Exists (0.2ms) SELECT 1 AS one FROM "payola_stripe_webhooks" WHERE "payola_stripe_webhooks"."stripe_id" = 'test_id' LIMIT 1
34254
+  (0.1ms) rollback transaction
34255
+  (0.0ms) begin transaction
34256
+  (0.1ms) SAVEPOINT active_record_1
34257
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-1' LIMIT 1
34258
+ SQL (0.3ms) INSERT INTO "subscription_plans" ("amount", "created_at", "interval", "interval_count", "name", "stripe_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?) [["amount", 100], ["created_at", "2014-11-07 00:20:51.888823"], ["interval", "month"], ["interval_count", 1], ["name", "Foo"], ["stripe_id", "foo-1"], ["updated_at", "2014-11-07 00:20:51.888823"]]
34259
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34260
+  (0.5ms) rollback transaction
34261
+  (0.1ms) begin transaction
34262
+  (0.1ms) rollback transaction
34263
+  (0.0ms) begin transaction
34264
+  (0.0ms) rollback transaction
34265
+  (0.1ms) begin transaction
34266
+  (0.0ms) rollback transaction
34267
+  (0.0ms) begin transaction
34268
+  (0.1ms) SAVEPOINT active_record_1
34269
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-1' LIMIT 1
34270
+ SQL (0.5ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:51.998198"], ["name", "Foo"], ["permalink", "foo-1"], ["price", 100], ["updated_at", "2014-11-07 00:20:51.998198"]]
34271
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34272
+  (0.1ms) SAVEPOINT active_record_1
34273
+ Payola::Sale Exists (0.2ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34274
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34275
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'c5hvt2' LIMIT 1
34276
+ SQL (1.1ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.004262"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "c5hvt2"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.004262"]]
34277
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34278
+  (0.0ms) SAVEPOINT active_record_1
34279
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'processing' WHERE "payola_sales"."id" = 1
34280
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34281
+  (0.6ms) rollback transaction
34282
+  (0.0ms) begin transaction
34283
+  (0.0ms) SAVEPOINT active_record_1
34284
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-2' LIMIT 1
34285
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.016104"], ["name", "Foo"], ["permalink", "foo-2"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.016104"]]
34286
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34287
+  (0.0ms) SAVEPOINT active_record_1
34288
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34289
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34290
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '9m8k2o' LIMIT 1
34291
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.018794"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "9m8k2o"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.018794"]]
34292
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34293
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '9m8k2o' AND "payola_sales"."id" != 1) LIMIT 1
34294
+  (0.1ms) SAVEPOINT active_record_1
34295
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-3' LIMIT 1
34296
+ SQL (0.1ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.023473"], ["name", "Foo"], ["permalink", "foo-3"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.023473"]]
34297
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34298
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '9m8k2o' LIMIT 1
34299
+  (0.5ms) rollback transaction
34300
+  (0.1ms) begin transaction
34301
+  (0.0ms) SAVEPOINT active_record_1
34302
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-4' LIMIT 1
34303
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.030162"], ["name", "Foo"], ["permalink", "foo-4"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.030162"]]
34304
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34305
+  (0.0ms) SAVEPOINT active_record_1
34306
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34307
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34308
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '58v28' LIMIT 1
34309
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.032889"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "58v28"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.032889"]]
34310
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34311
+  (0.1ms) SAVEPOINT active_record_1
34312
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
34313
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34314
+  (0.5ms) rollback transaction
34315
+  (0.0ms) begin transaction
34316
+  (0.1ms) SAVEPOINT active_record_1
34317
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-5' LIMIT 1
34318
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.039205"], ["name", "Foo"], ["permalink", "foo-5"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.039205"]]
34319
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34320
+  (0.0ms) SAVEPOINT active_record_1
34321
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34322
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34323
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'jn2s2d' LIMIT 1
34324
+ SQL (0.4ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.042157"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "jn2s2d"], ["product_id", 1], ["product_type", "Product"], ["state", "finished"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.042157"]]
34325
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34326
+  (0.1ms) SAVEPOINT active_record_1
34327
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'refunded' WHERE "payola_sales"."id" = 1
34328
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34329
+  (0.6ms) rollback transaction
34330
+  (0.0ms) begin transaction
34331
+  (0.0ms) SAVEPOINT active_record_1
34332
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-6' LIMIT 1
34333
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.048157"], ["name", "Foo"], ["permalink", "foo-6"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.048157"]]
34334
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34335
+  (0.0ms) SAVEPOINT active_record_1
34336
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34337
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34338
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '6m1590' LIMIT 1
34339
+ SQL (0.4ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.050686"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "6m1590"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.050686"]]
34340
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34341
+  (0.1ms) SAVEPOINT active_record_1
34342
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'errored' WHERE "payola_sales"."id" = 1
34343
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34344
+  (0.5ms) rollback transaction
34345
+  (0.1ms) begin transaction
34346
+  (0.0ms) SAVEPOINT active_record_1
34347
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-7' LIMIT 1
34348
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.056974"], ["name", "Foo"], ["permalink", "foo-7"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.056974"]]
34349
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34350
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34351
+  (0.4ms) rollback transaction
34352
+  (0.0ms) begin transaction
34353
+  (0.0ms) SAVEPOINT active_record_1
34354
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-8' LIMIT 1
34355
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.061066"], ["name", "Foo"], ["permalink", "foo-8"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.061066"]]
34356
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34357
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34358
+  (0.4ms) rollback transaction
34359
+  (0.0ms) begin transaction
34360
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34361
+  (0.1ms) rollback transaction
34362
+  (0.0ms) begin transaction
34363
+  (0.0ms) SAVEPOINT active_record_1
34364
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-9' LIMIT 1
34365
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.069030"], ["name", "Foo"], ["permalink", "foo-9"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.069030"]]
34366
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34367
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34368
+  (0.4ms) rollback transaction
34369
+  (0.0ms) begin transaction
34370
+  (0.0ms) SAVEPOINT active_record_1
34371
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-10' LIMIT 1
34372
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.073858"], ["name", "Foo"], ["permalink", "foo-10"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.073858"]]
34373
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34374
+  (0.1ms) SAVEPOINT active_record_1
34375
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34376
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34377
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'pah5s7' LIMIT 1
34378
+ SQL (0.4ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.076943"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "pah5s7"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.076943"]]
34379
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34380
+  (0.1ms) SAVEPOINT active_record_1
34381
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'pah5s7' AND "payola_sales"."id" != 1) LIMIT 1
34382
+ SQL (0.1ms) UPDATE "payola_sales" SET "signed_custom_fields" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["signed_custom_fields", "BAh7BkkiCmZpZWxkBjoGRUZJIgp2YWx1ZQY7AEY=--5d721d50404afc54672ec88747e606e4226813b1fdb826dff62844c014ca61fc"], ["updated_at", "2014-11-07 00:20:52.080802"]]
34383
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34384
+ Payola::Sale Load (0.2ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34385
+  (0.6ms) rollback transaction
34386
+  (0.1ms) begin transaction
34387
+  (0.1ms) SAVEPOINT active_record_1
34388
+ Product Exists (0.2ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-11' LIMIT 1
34389
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.088476"], ["name", "Foo"], ["permalink", "foo-11"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.088476"]]
34390
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34391
+  (0.0ms) SAVEPOINT active_record_1
34392
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34393
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34394
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'e1n3l3' LIMIT 1
34395
+ SQL (0.4ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.092298"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "e1n3l3"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.092298"]]
34396
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34397
+  (0.0ms) SAVEPOINT active_record_1
34398
+ SQL (0.1ms) INSERT INTO "owners" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-07 00:20:52.096433"], ["updated_at", "2014-11-07 00:20:52.096433"]]
34399
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34400
+  (0.0ms) SAVEPOINT active_record_1
34401
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'e1n3l3' AND "payola_sales"."id" != 1) LIMIT 1
34402
+ SQL (0.1ms) UPDATE "payola_sales" SET "owner_id" = ?, "owner_type" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["owner_id", 1], ["owner_type", "Owner"], ["updated_at", "2014-11-07 00:20:52.100819"]]
34403
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34404
+  (0.6ms) rollback transaction
34405
+  (0.1ms) begin transaction
34406
+ Product Exists (0.2ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-12' LIMIT 1
34407
+  (0.1ms) rollback transaction
34408
+  (0.0ms) begin transaction
34409
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-13' LIMIT 1
34410
+  (0.1ms) rollback transaction
34411
+  (0.0ms) begin transaction
34412
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'f' LIMIT 1
34413
+  (0.1ms) rollback transaction
34414
+  (0.0ms) begin transaction
34415
+  (0.0ms) rollback transaction
34416
+  (0.1ms) begin transaction
34417
+  (0.1ms) rollback transaction
34418
+  (0.0ms) begin transaction
34419
+  (0.1ms) SAVEPOINT active_record_1
34420
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-15' LIMIT 1
34421
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.161494"], ["name", "Foo"], ["permalink", "foo-15"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.161494"]]
34422
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34423
+ Processing by Payola::TransactionsController#create as HTML
34424
+ Parameters: {"product_class"=>"product", "permalink"=>"foo-15"}
34425
+ Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."permalink" = 'foo-15' LIMIT 1
34426
+ Payola::Coupon Load (0.1ms) SELECT "payola_coupons".* FROM "payola_coupons" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_coupons"."id" ASC LIMIT 1
34427
+ Payola::Affiliate Load (0.1ms) SELECT "payola_affiliates".* FROM "payola_affiliates" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_affiliates"."id" ASC LIMIT 1
34428
+ Completed 200 OK in 10ms (Views: 0.2ms | ActiveRecord: 0.6ms)
34429
+  (0.4ms) rollback transaction
34430
+  (0.0ms) begin transaction
34431
+  (0.0ms) SAVEPOINT active_record_1
34432
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-16' LIMIT 1
34433
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.180316"], ["name", "Foo"], ["permalink", "foo-16"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.180316"]]
34434
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34435
+ Processing by Payola::TransactionsController#create as HTML
34436
+ Parameters: {"product_class"=>"product", "permalink"=>"foo-16"}
34437
+ Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."permalink" = 'foo-16' LIMIT 1
34438
+ Payola::Coupon Load (0.1ms) SELECT "payola_coupons".* FROM "payola_coupons" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_coupons"."id" ASC LIMIT 1
34439
+ Payola::Affiliate Load (0.1ms) SELECT "payola_affiliates".* FROM "payola_affiliates" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_affiliates"."id" ASC LIMIT 1
34440
+ Completed 400 Bad Request in 2ms (Views: 0.2ms | ActiveRecord: 0.2ms)
34441
+  (0.3ms) rollback transaction
34442
+  (0.0ms) begin transaction
34443
+  (0.0ms) SAVEPOINT active_record_1
34444
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-17' LIMIT 1
34445
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.188172"], ["name", "Foo"], ["permalink", "foo-17"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.188172"]]
34446
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34447
+  (0.0ms) SAVEPOINT active_record_1
34448
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-18' LIMIT 1
34449
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.190366"], ["name", "Foo"], ["permalink", "foo-18"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.190366"]]
34450
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34451
+  (0.0ms) SAVEPOINT active_record_1
34452
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34453
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34454
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'gdcb88' LIMIT 1
34455
+ SQL (0.1ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.192838"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "gdcb88"], ["product_id", 2], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.192838"]]
34456
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34457
+ Processing by Payola::TransactionsController#status as HTML
34458
+ Parameters: {"guid"=>"gdcb88"}
34459
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."guid" = 'gdcb88' ORDER BY "payola_sales"."id" ASC LIMIT 1
34460
+ Completed 200 OK in 1ms (Views: 0.2ms | ActiveRecord: 0.1ms)
34461
+  (0.5ms) rollback transaction
34462
+  (0.1ms) begin transaction
34463
+  (0.1ms) SAVEPOINT active_record_1
34464
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-19' LIMIT 1
34465
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.199701"], ["name", "Foo"], ["permalink", "foo-19"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.199701"]]
34466
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34467
+ Processing by Payola::TransactionsController#status as HTML
34468
+ Parameters: {"guid"=>"doesnotexist"}
34469
+ Payola::Sale Load (0.2ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."guid" = 'doesnotexist' ORDER BY "payola_sales"."id" ASC LIMIT 1
34470
+ Completed 404 Not Found in 14ms (Views: 13.2ms | ActiveRecord: 0.2ms)
34471
+  (0.4ms) rollback transaction
34472
+  (0.0ms) begin transaction
34473
+  (0.0ms) SAVEPOINT active_record_1
34474
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-20' LIMIT 1
34475
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.220071"], ["name", "Foo"], ["permalink", "foo-20"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.220071"]]
34476
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34477
+  (0.0ms) SAVEPOINT active_record_1
34478
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-21' LIMIT 1
34479
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.222207"], ["name", "Foo"], ["permalink", "foo-21"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.222207"]]
34480
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34481
+  (0.0ms) SAVEPOINT active_record_1
34482
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34483
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34484
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'mq18gc' LIMIT 1
34485
+ SQL (0.1ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.224735"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "mq18gc"], ["product_id", 2], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.224735"]]
34486
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34487
+ Processing by Payola::TransactionsController#show as HTML
34488
+ Parameters: {"guid"=>"mq18gc"}
34489
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."guid" = 'mq18gc' LIMIT 1
34490
+ Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT 1 [["id", 2]]
34491
+ Redirected to http://test.host/
34492
+ Completed 302 Found in 6ms (ActiveRecord: 0.3ms)
34493
+  (0.6ms) rollback transaction
34494
+  (0.0ms) begin transaction
34495
+  (0.0ms) rollback transaction
34496
+  (0.0ms) begin transaction
34497
+  (0.0ms) rollback transaction
34498
+  (0.0ms) begin transaction
34499
+  (0.0ms) rollback transaction
34500
+  (0.0ms) begin transaction
34501
+  (0.1ms) rollback transaction
34502
+  (0.0ms) begin transaction
34503
+  (0.1ms) rollback transaction
34504
+  (0.0ms) begin transaction
34505
+  (0.0ms) rollback transaction
34506
+  (0.0ms) begin transaction
34507
+  (0.0ms) SAVEPOINT active_record_1
34508
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-2' LIMIT 1
34509
+ SQL (0.2ms) INSERT INTO "subscription_plans" ("amount", "created_at", "interval", "interval_count", "name", "stripe_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?) [["amount", 100], ["created_at", "2014-11-07 00:20:52.247738"], ["interval", "month"], ["interval_count", 1], ["name", "Foo"], ["stripe_id", "foo-2"], ["updated_at", "2014-11-07 00:20:52.247738"]]
34510
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34511
+  (0.0ms) SAVEPOINT active_record_1
34512
+ SQL (0.4ms) INSERT INTO "payola_subscriptions" ("cancel_at_period_end", "canceled_at", "created_at", "current_period_end", "current_period_start", "ended_at", "owner_id", "owner_type", "plan_id", "plan_type", "quantity", "start", "state", "status", "stripe_customer_id", "stripe_token", "trial_end", "trial_start", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["cancel_at_period_end", "f"], ["canceled_at", "2014-11-04 22:34:39.000000"], ["created_at", "2014-11-07 00:20:52.250876"], ["current_period_end", "2014-11-04 22:34:39.000000"], ["current_period_start", "2014-11-04 22:34:39.000000"], ["ended_at", "2014-11-04 22:34:39.000000"], ["owner_id", 1], ["owner_type", "MyString"], ["plan_id", 1], ["plan_type", "SubscriptionPlan"], ["quantity", 1], ["start", "2014-11-04 22:34:39.000000"], ["state", "processing"], ["status", "MyString"], ["stripe_customer_id", "MyString"], ["stripe_token", "test_tok_1"], ["trial_end", "2014-11-04 22:34:39.000000"], ["trial_start", "2014-11-04 22:34:39.000000"], ["updated_at", "2014-11-07 00:20:52.250876"]]
34513
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34514
+ Payola::Subscription Load (0.1ms) SELECT "payola_subscriptions".* FROM "payola_subscriptions" WHERE "payola_subscriptions"."id" = ? LIMIT 1 [["id", 1]]
34515
+ SubscriptionPlan Load (0.1ms) SELECT "subscription_plans".* FROM "subscription_plans" WHERE "subscription_plans"."id" = ? LIMIT 1 [["id", 1]]
34516
+  (0.1ms) SAVEPOINT active_record_1
34517
+ SQL (0.2ms) UPDATE "payola_subscriptions" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_subscriptions"."id" = 1 [["card_expiration", "2016-04-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["stripe_customer_id", "test_cus_3"], ["stripe_id", "test_su_4"], ["updated_at", "2014-11-07 00:20:52.257617"]]
34518
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34519
+  (0.1ms) SAVEPOINT active_record_1
34520
+ SQL (0.1ms) UPDATE "payola_subscriptions" SET "state" = 'finished' WHERE "payola_subscriptions"."id" = 1
34521
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34522
+ Payola::Subscription Load (0.1ms) SELECT "payola_subscriptions".* FROM "payola_subscriptions" WHERE "payola_subscriptions"."id" = ? LIMIT 1 [["id", 1]]
34523
+ Payola::Subscription Load (0.1ms) SELECT "payola_subscriptions".* FROM "payola_subscriptions" WHERE "payola_subscriptions"."id" = ? LIMIT 1 [["id", 1]]
34524
+ Payola::Subscription Load (0.1ms) SELECT "payola_subscriptions".* FROM "payola_subscriptions" WHERE "payola_subscriptions"."id" = ? LIMIT 1 [["id", 1]]
34525
+ Payola::Subscription Load (0.0ms) SELECT "payola_subscriptions".* FROM "payola_subscriptions" WHERE "payola_subscriptions"."id" = ? LIMIT 1 [["id", 1]]
34526
+  (0.5ms) rollback transaction
34527
+  (0.1ms) begin transaction
34528
+  (0.1ms) SAVEPOINT active_record_1
34529
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-3' LIMIT 1
34530
+ SQL (0.2ms) INSERT INTO "subscription_plans" ("amount", "created_at", "interval", "interval_count", "name", "stripe_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?) [["amount", 100], ["created_at", "2014-11-07 00:20:52.268912"], ["interval", "month"], ["interval_count", 1], ["name", "Foo"], ["stripe_id", "foo-3"], ["updated_at", "2014-11-07 00:20:52.268912"]]
34531
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34532
+  (0.0ms) SAVEPOINT active_record_1
34533
+ SQL (0.3ms) INSERT INTO "payola_subscriptions" ("cancel_at_period_end", "canceled_at", "created_at", "current_period_end", "current_period_start", "ended_at", "owner_id", "owner_type", "plan_id", "plan_type", "quantity", "start", "state", "status", "stripe_customer_id", "stripe_token", "trial_end", "trial_start", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["cancel_at_period_end", "f"], ["canceled_at", "2014-11-04 22:34:39.000000"], ["created_at", "2014-11-07 00:20:52.272237"], ["current_period_end", "2014-11-04 22:34:39.000000"], ["current_period_start", "2014-11-04 22:34:39.000000"], ["ended_at", "2014-11-04 22:34:39.000000"], ["owner_id", 1], ["owner_type", "MyString"], ["plan_id", 1], ["plan_type", "SubscriptionPlan"], ["quantity", 1], ["start", "2014-11-04 22:34:39.000000"], ["state", "processing"], ["status", "MyString"], ["stripe_customer_id", "MyString"], ["stripe_token", "test_tok_1"], ["trial_end", "2014-11-04 22:34:39.000000"], ["trial_start", "2014-11-04 22:34:39.000000"], ["updated_at", "2014-11-07 00:20:52.272237"]]
34534
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34535
+ Payola::Subscription Load (0.0ms) SELECT "payola_subscriptions".* FROM "payola_subscriptions" WHERE "payola_subscriptions"."id" = ? LIMIT 1 [["id", 1]]
34536
+ SubscriptionPlan Load (0.0ms) SELECT "subscription_plans".* FROM "subscription_plans" WHERE "subscription_plans"."id" = ? LIMIT 1 [["id", 1]]
34537
+  (0.1ms) SAVEPOINT active_record_1
34538
+ SQL (0.1ms) UPDATE "payola_subscriptions" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_subscriptions"."id" = 1 [["card_expiration", "2016-04-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["stripe_customer_id", "test_cus_3"], ["stripe_id", "test_su_4"], ["updated_at", "2014-11-07 00:20:52.276813"]]
34539
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34540
+  (0.0ms) SAVEPOINT active_record_1
34541
+ SQL (0.1ms) UPDATE "payola_subscriptions" SET "state" = 'finished' WHERE "payola_subscriptions"."id" = 1
34542
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34543
+ Payola::Subscription Load (0.1ms) SELECT "payola_subscriptions".* FROM "payola_subscriptions" WHERE "payola_subscriptions"."id" = ? LIMIT 1 [["id", 1]]
34544
+  (0.6ms) rollback transaction
34545
+  (0.0ms) begin transaction
34546
+  (0.0ms) SAVEPOINT active_record_1
34547
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-4' LIMIT 1
34548
+ SQL (0.2ms) INSERT INTO "subscription_plans" ("amount", "created_at", "interval", "interval_count", "name", "stripe_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?) [["amount", 100], ["created_at", "2014-11-07 00:20:52.282839"], ["interval", "month"], ["interval_count", 1], ["name", "Foo"], ["stripe_id", "foo-4"], ["updated_at", "2014-11-07 00:20:52.282839"]]
34549
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34550
+  (0.3ms) rollback transaction
34551
+  (0.0ms) begin transaction
34552
+  (0.0ms) SAVEPOINT active_record_1
34553
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-22' LIMIT 1
34554
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.286977"], ["name", "Foo"], ["permalink", "foo-22"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.286977"]]
34555
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34556
+  (0.0ms) SAVEPOINT active_record_1
34557
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34558
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34559
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '8kcavj' LIMIT 1
34560
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.289557"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "8kcavj"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.289557"]]
34561
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34562
+  (0.1ms) SAVEPOINT active_record_1
34563
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '8kcavj' AND "payola_sales"."id" != 1) LIMIT 1
34564
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34565
+  (0.1ms) SAVEPOINT active_record_1
34566
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '8kcavj' AND "payola_sales"."id" != 1) LIMIT 1
34567
+ SQL (0.1ms) UPDATE "payola_sales" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "fee_amount" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["card_expiration", "2013-12-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["fee_amount", 0], ["stripe_customer_id", "test_cus_1"], ["stripe_id", "test_ch_3"], ["updated_at", "2014-11-07 00:20:52.293770"]]
34568
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34569
+  (0.0ms) SAVEPOINT active_record_1
34570
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
34571
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34572
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34573
+  (0.6ms) rollback transaction
34574
+  (0.1ms) begin transaction
34575
+  (0.0ms) SAVEPOINT active_record_1
34576
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-23' LIMIT 1
34577
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.299026"], ["name", "Foo"], ["permalink", "foo-23"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.299026"]]
34578
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34579
+  (0.0ms) SAVEPOINT active_record_1
34580
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34581
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34582
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '5lvagl' LIMIT 1
34583
+ SQL (0.4ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.301628"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "5lvagl"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.301628"]]
34584
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34585
+  (0.0ms) SAVEPOINT active_record_1
34586
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '5lvagl' AND "payola_sales"."id" != 1) LIMIT 1
34587
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34588
+  (0.0ms) SAVEPOINT active_record_1
34589
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '5lvagl' AND "payola_sales"."id" != 1) LIMIT 1
34590
+ SQL (0.1ms) UPDATE "payola_sales" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "fee_amount" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["card_expiration", "2013-12-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["fee_amount", 0], ["stripe_customer_id", "test_cus_1"], ["stripe_id", "test_ch_3"], ["updated_at", "2014-11-07 00:20:52.305445"]]
34591
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34592
+  (0.1ms) SAVEPOINT active_record_1
34593
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
34594
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34595
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34596
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34597
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34598
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34599
+  (0.6ms) rollback transaction
34600
+  (0.1ms) begin transaction
34601
+  (0.0ms) SAVEPOINT active_record_1
34602
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-24' LIMIT 1
34603
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.311704"], ["name", "Foo"], ["permalink", "foo-24"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.311704"]]
34604
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34605
+  (0.0ms) SAVEPOINT active_record_1
34606
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34607
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34608
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'sqb728' LIMIT 1
34609
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.314407"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "sqb728"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.314407"]]
34610
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34611
+  (0.1ms) SAVEPOINT active_record_1
34612
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'sqb728' AND "payola_sales"."id" != 1) LIMIT 1
34613
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34614
+  (0.1ms) SAVEPOINT active_record_1
34615
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'sqb728' AND "payola_sales"."id" != 1) LIMIT 1
34616
+ SQL (0.1ms) UPDATE "payola_sales" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "fee_amount" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["card_expiration", "2013-12-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["fee_amount", 0], ["stripe_customer_id", "test_cus_1"], ["stripe_id", "test_ch_3"], ["updated_at", "2014-11-07 00:20:52.318930"]]
34617
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34618
+  (0.1ms) SAVEPOINT active_record_1
34619
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
34620
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34621
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34622
+  (0.6ms) rollback transaction
34623
+  (0.1ms) begin transaction
34624
+  (0.0ms) SAVEPOINT active_record_1
34625
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-25' LIMIT 1
34626
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.325486"], ["name", "Foo"], ["permalink", "foo-25"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.325486"]]
34627
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34628
+  (0.0ms) SAVEPOINT active_record_1
34629
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34630
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34631
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'aamks3' LIMIT 1
34632
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.329158"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "aamks3"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 00:20:52.329158"]]
34633
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34634
+  (0.0ms) SAVEPOINT active_record_1
34635
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'aamks3' AND "payola_sales"."id" != 1) LIMIT 1
34636
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34637
+  (0.0ms) SAVEPOINT active_record_1
34638
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'aamks3' AND "payola_sales"."id" != 1) LIMIT 1
34639
+ SQL (0.1ms) UPDATE "payola_sales" SET "error" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["error", "The card was declined"], ["updated_at", "2014-11-07 00:20:52.332861"]]
34640
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34641
+  (0.0ms) SAVEPOINT active_record_1
34642
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'errored' WHERE "payola_sales"."id" = 1
34643
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34644
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34645
+  (0.6ms) rollback transaction
34646
+  (0.0ms) begin transaction
34647
+  (0.1ms) rollback transaction
34648
+  (0.0ms) begin transaction
34649
+  (0.0ms) rollback transaction
34650
+  (0.0ms) begin transaction
34651
+  (0.0ms) rollback transaction
34652
+  (0.0ms) begin transaction
34653
+  (0.0ms) rollback transaction
34654
+  (0.0ms) begin transaction
34655
+  (0.0ms) SAVEPOINT active_record_1
34656
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-5' LIMIT 1
34657
+ SQL (0.3ms) INSERT INTO "subscription_plans" ("amount", "created_at", "interval", "interval_count", "name", "stripe_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?) [["amount", 100], ["created_at", "2014-11-07 00:20:52.345507"], ["interval", "month"], ["interval_count", 1], ["name", "Foo"], ["stripe_id", "foo-5"], ["updated_at", "2014-11-07 00:20:52.345507"]]
34658
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34659
+ Processing by Payola::SubscriptionsController#create as HTML
34660
+ Parameters: {"plan_class"=>"subscription_plan", "plan_id"=>"1"}
34661
+ SubscriptionPlan Load (0.1ms) SELECT "subscription_plans".* FROM "subscription_plans" WHERE "subscription_plans"."id" = 1 LIMIT 1
34662
+ Completed 200 OK in 1ms (Views: 0.2ms | ActiveRecord: 0.1ms)
34663
+  (0.5ms) rollback transaction
34664
+  (0.1ms) begin transaction
34665
+  (0.0ms) SAVEPOINT active_record_1
34666
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-6' LIMIT 1
34667
+ SQL (0.2ms) INSERT INTO "subscription_plans" ("amount", "created_at", "interval", "interval_count", "name", "stripe_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?) [["amount", 100], ["created_at", "2014-11-07 00:20:52.397908"], ["interval", "month"], ["interval_count", 1], ["name", "Foo"], ["stripe_id", "foo-6"], ["updated_at", "2014-11-07 00:20:52.397908"]]
34668
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34669
+ Processing by Payola::SubscriptionsController#create as HTML
34670
+ Parameters: {"plan_class"=>"subscription_plan", "plan_id"=>"1"}
34671
+ SubscriptionPlan Load (0.1ms) SELECT "subscription_plans".* FROM "subscription_plans" WHERE "subscription_plans"."id" = 1 LIMIT 1
34672
+ Completed 400 Bad Request in 1ms (Views: 0.2ms | ActiveRecord: 0.1ms)
34673
+  (0.4ms) rollback transaction
34674
+  (0.1ms) begin transaction
34675
+  (0.1ms) rollback transaction
34676
+  (0.1ms) begin transaction
34677
+  (0.0ms) rollback transaction
34678
+  (0.0ms) begin transaction
34679
+  (0.1ms) rollback transaction
34680
+  (0.1ms) begin transaction
34681
+  (0.1ms) rollback transaction
34682
+  (0.0ms) begin transaction
34683
+  (0.0ms) rollback transaction
34684
+  (0.0ms) begin transaction
34685
+  (0.1ms) rollback transaction
34686
+  (0.0ms) begin transaction
34687
+  (0.1ms) rollback transaction
34688
+  (0.0ms) begin transaction
34689
+  (0.1ms) rollback transaction
34690
+  (0.0ms) begin transaction
34691
+  (0.1ms) rollback transaction
34692
+  (0.0ms) begin transaction
34693
+  (0.0ms) rollback transaction
34694
+  (0.0ms) begin transaction
34695
+  (0.0ms) rollback transaction
34696
+  (0.0ms) begin transaction
34697
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-7' LIMIT 1
34698
+  (0.1ms) rollback transaction
34699
+  (0.0ms) begin transaction
34700
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-8' LIMIT 1
34701
+  (0.1ms) rollback transaction
34702
+  (0.0ms) begin transaction
34703
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-9' LIMIT 1
34704
+  (0.1ms) rollback transaction
34705
+  (0.0ms) begin transaction
34706
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-10' LIMIT 1
34707
+  (0.1ms) rollback transaction
34708
+  (0.0ms) begin transaction
34709
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" IS NULL LIMIT 1
34710
+  (0.1ms) rollback transaction
34711
+  (0.0ms) begin transaction
34712
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-11' LIMIT 1
34713
+  (0.1ms) rollback transaction
34714
+  (0.0ms) begin transaction
34715
+  (0.0ms) SAVEPOINT active_record_1
34716
+ SubscriptionPlan Exists (0.1ms) SELECT 1 AS one FROM "subscription_plans" WHERE "subscription_plans"."stripe_id" = 'foo-12' LIMIT 1
34717
+ SQL (0.3ms) INSERT INTO "subscription_plans" ("amount", "created_at", "interval", "interval_count", "name", "stripe_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?) [["amount", 100], ["created_at", "2014-11-07 00:20:52.457729"], ["interval", "month"], ["interval_count", 1], ["name", "Foo"], ["stripe_id", "foo-12"], ["updated_at", "2014-11-07 00:20:52.457729"]]
34718
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34719
+  (0.4ms) rollback transaction
34720
+  (0.1ms) begin transaction
34721
+  (0.1ms) rollback transaction
34722
+  (0.0ms) begin transaction
34723
+  (0.0ms) rollback transaction
34724
+  (0.0ms) begin transaction
34725
+  (0.0ms) SAVEPOINT active_record_1
34726
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-26' LIMIT 1
34727
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.464086"], ["name", "Foo"], ["permalink", "foo-26"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.464086"]]
34728
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34729
+  (0.1ms) SAVEPOINT active_record_1
34730
+ Payola::Affiliate Exists (0.1ms) SELECT 1 AS one FROM "payola_affiliates" WHERE "payola_affiliates"."code" = 'MyString' LIMIT 1
34731
+ SQL (0.4ms) INSERT INTO "payola_affiliates" ("code", "created_at", "email", "percent", "updated_at") VALUES (?, ?, ?, ?, ?) [["code", "MyString"], ["created_at", "2014-11-07 00:20:52.472802"], ["email", "foo@example.com"], ["percent", 100], ["updated_at", "2014-11-07 00:20:52.472802"]]
34732
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34733
+ Payola::Affiliate Load (0.1ms) SELECT "payola_affiliates".* FROM "payola_affiliates" WHERE "payola_affiliates"."id" = ? LIMIT 1 [["id", 1]]
34734
+  (0.5ms) rollback transaction
34735
+  (0.1ms) begin transaction
34736
+  (0.1ms) SAVEPOINT active_record_1
34737
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-27' LIMIT 1
34738
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.480570"], ["name", "Foo"], ["permalink", "foo-27"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.480570"]]
34739
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34740
+  (0.4ms) rollback transaction
34741
+  (0.1ms) begin transaction
34742
+  (0.1ms) SAVEPOINT active_record_1
34743
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-28' LIMIT 1
34744
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.486001"], ["name", "Foo"], ["permalink", "foo-28"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.486001"]]
34745
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34746
+  (0.1ms) SAVEPOINT active_record_1
34747
+ Payola::Coupon Exists (0.1ms) SELECT 1 AS one FROM "payola_coupons" WHERE "payola_coupons"."code" = 'MyString' LIMIT 1
34748
+ SQL (0.4ms) INSERT INTO "payola_coupons" ("code", "created_at", "percent_off", "updated_at") VALUES (?, ?, ?, ?) [["code", "MyString"], ["created_at", "2014-11-07 00:20:52.495132"], ["percent_off", 1], ["updated_at", "2014-11-07 00:20:52.495132"]]
34749
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34750
+  (0.5ms) rollback transaction
34751
+  (0.1ms) begin transaction
34752
+  (0.1ms) SAVEPOINT active_record_1
34753
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-29' LIMIT 1
34754
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 00:20:52.503732"], ["name", "Foo"], ["permalink", "foo-29"], ["price", 100], ["updated_at", "2014-11-07 00:20:52.503732"]]
34755
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34756
+  (0.0ms) SAVEPOINT active_record_1
34757
+ Payola::Coupon Exists (0.1ms) SELECT 1 AS one FROM "payola_coupons" WHERE "payola_coupons"."code" = 'MyString' LIMIT 1
34758
+ SQL (0.4ms) INSERT INTO "payola_coupons" ("code", "created_at", "percent_off", "updated_at") VALUES (?, ?, ?, ?) [["code", "MyString"], ["created_at", "2014-11-07 00:20:52.506500"], ["percent_off", 1], ["updated_at", "2014-11-07 00:20:52.506500"]]
34759
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34760
+  (0.4ms) rollback transaction
34761
+  (1.5ms) CREATE TABLE "owners" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) 
34762
+  (1.0ms) CREATE TABLE "payola_affiliates" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "code" varchar(255), "email" varchar(255), "percent" integer, "created_at" datetime, "updated_at" datetime)
34763
+  (0.9ms) CREATE TABLE "payola_coupons" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "code" varchar(255), "percent_off" integer, "created_at" datetime, "updated_at" datetime) 
34764
+  (0.9ms) CREATE TABLE "payola_sales" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "email" varchar(255), "guid" varchar(255), "product_id" integer, "product_type" varchar(255), "created_at" datetime, "updated_at" datetime, "state" varchar(255), "stripe_id" varchar(255), "stripe_token" varchar(255), "card_last4" varchar(255), "card_expiration" date, "card_type" varchar(255), "error" text, "amount" integer, "fee_amount" integer, "coupon_id" integer, "opt_in" boolean, "download_count" integer, "affiliate_id" integer, "customer_address" text, "business_address" text, "stripe_customer_id" varchar(255), "currency" varchar(255), "signed_custom_fields" text, "owner_id" integer, "owner_type" varchar(255))
34765
+  (0.2ms) select sqlite_version(*)
34766
+  (1.0ms) CREATE INDEX "index_payola_sales_on_coupon_id" ON "payola_sales" ("coupon_id")
34767
+  (0.1ms)  SELECT sql
34768
+ FROM sqlite_master
34769
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34770
+ UNION ALL
34771
+ SELECT sql
34772
+ FROM sqlite_temp_master
34773
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34774
+ 
34775
+  (0.8ms) CREATE INDEX "index_payola_sales_on_email" ON "payola_sales" ("email")
34776
+  (0.1ms)  SELECT sql
34777
+ FROM sqlite_master
34778
+ WHERE name='index_payola_sales_on_email' AND type='index'
34779
+ UNION ALL
34780
+ SELECT sql
34781
+ FROM sqlite_temp_master
34782
+ WHERE name='index_payola_sales_on_email' AND type='index'
34783
+ 
34784
+  (0.1ms) SELECT sql
34785
+ FROM sqlite_master
34786
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34787
+ UNION ALL
34788
+ SELECT sql
34789
+ FROM sqlite_temp_master
34790
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34791
+
34792
+  (0.7ms) CREATE INDEX "index_payola_sales_on_guid" ON "payola_sales" ("guid")
34793
+  (0.1ms) SELECT sql
34794
+ FROM sqlite_master
34795
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34796
+ UNION ALL
34797
+ SELECT sql
34798
+ FROM sqlite_temp_master
34799
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34800
+
34801
+  (0.1ms)  SELECT sql
34802
+ FROM sqlite_master
34803
+ WHERE name='index_payola_sales_on_email' AND type='index'
34804
+ UNION ALL
34805
+ SELECT sql
34806
+ FROM sqlite_temp_master
34807
+ WHERE name='index_payola_sales_on_email' AND type='index'
34808
+ 
34809
+  (0.1ms) SELECT sql
34810
+ FROM sqlite_master
34811
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34812
+ UNION ALL
34813
+ SELECT sql
34814
+ FROM sqlite_temp_master
34815
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34816
+
34817
+  (0.8ms) CREATE INDEX "index_payola_sales_on_owner_id_and_owner_type" ON "payola_sales" ("owner_id", "owner_type")
34818
+  (0.1ms) SELECT sql
34819
+ FROM sqlite_master
34820
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34821
+ UNION ALL
34822
+ SELECT sql
34823
+ FROM sqlite_temp_master
34824
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34825
+
34826
+  (0.1ms)  SELECT sql
34827
+ FROM sqlite_master
34828
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34829
+ UNION ALL
34830
+ SELECT sql
34831
+ FROM sqlite_temp_master
34832
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34833
+ 
34834
+  (0.1ms) SELECT sql
34835
+ FROM sqlite_master
34836
+ WHERE name='index_payola_sales_on_email' AND type='index'
34837
+ UNION ALL
34838
+ SELECT sql
34839
+ FROM sqlite_temp_master
34840
+ WHERE name='index_payola_sales_on_email' AND type='index'
34841
+
34842
+  (0.1ms)  SELECT sql
34843
+ FROM sqlite_master
34844
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34845
+ UNION ALL
34846
+ SELECT sql
34847
+ FROM sqlite_temp_master
34848
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34849
+ 
34850
+  (0.7ms) CREATE INDEX "index_payola_sales_on_product" ON "payola_sales" ("product_id", "product_type")
34851
+  (0.1ms)  SELECT sql
34852
+ FROM sqlite_master
34853
+ WHERE name='index_payola_sales_on_product' AND type='index'
34854
+ UNION ALL
34855
+ SELECT sql
34856
+ FROM sqlite_temp_master
34857
+ WHERE name='index_payola_sales_on_product' AND type='index'
34858
+ 
34859
+  (0.1ms) SELECT sql
34860
+ FROM sqlite_master
34861
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34862
+ UNION ALL
34863
+ SELECT sql
34864
+ FROM sqlite_temp_master
34865
+ WHERE name='index_payola_sales_on_owner_id_and_owner_type' AND type='index'
34866
+
34867
+  (0.1ms)  SELECT sql
34868
+ FROM sqlite_master
34869
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34870
+ UNION ALL
34871
+ SELECT sql
34872
+ FROM sqlite_temp_master
34873
+ WHERE name='index_payola_sales_on_guid' AND type='index'
34874
+ 
34875
+  (0.1ms) SELECT sql
34876
+ FROM sqlite_master
34877
+ WHERE name='index_payola_sales_on_email' AND type='index'
34878
+ UNION ALL
34879
+ SELECT sql
34880
+ FROM sqlite_temp_master
34881
+ WHERE name='index_payola_sales_on_email' AND type='index'
34882
+
34883
+  (0.1ms)  SELECT sql
34884
+ FROM sqlite_master
34885
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34886
+ UNION ALL
34887
+ SELECT sql
34888
+ FROM sqlite_temp_master
34889
+ WHERE name='index_payola_sales_on_coupon_id' AND type='index'
34890
+ 
34891
+  (0.9ms) CREATE INDEX "index_payola_sales_on_stripe_customer_id" ON "payola_sales" ("stripe_customer_id")
34892
+  (0.9ms) CREATE TABLE "payola_stripe_webhooks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "stripe_id" varchar(255), "created_at" datetime, "updated_at" datetime) 
34893
+  (0.9ms) CREATE TABLE "products" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "permalink" varchar(255), "price" integer, "created_at" datetime, "updated_at" datetime)
34894
+  (1.0ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
34895
+  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
34896
+  (0.1ms) SELECT version FROM "schema_migrations"
34897
+  (0.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20141029140518')
34898
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141001230848')
34899
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141001170138')
34900
+  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20141001203541')
34901
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141002013618')
34902
+  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20141002013701')
34903
+  (0.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20141002203725')
34904
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141017233304')
34905
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141026101628')
34906
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141026144800')
34907
+  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20141029135848')
34908
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
34909
+  (0.1ms) begin transaction
34910
+  (0.1ms) rollback transaction
34911
+  (0.1ms) begin transaction
34912
+  (0.0ms) rollback transaction
34913
+  (0.0ms) begin transaction
34914
+  (0.1ms) SAVEPOINT active_record_1
34915
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-1' LIMIT 1
34916
+ SQL (0.5ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.215345"], ["name", "Foo"], ["permalink", "foo-1"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.215345"]]
34917
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34918
+  (0.1ms) SAVEPOINT active_record_1
34919
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34920
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34921
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'op7eu8' LIMIT 1
34922
+ SQL (1.0ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.231439"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "op7eu8"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.231439"]]
34923
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34924
+  (0.0ms) SAVEPOINT active_record_1
34925
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'op7eu8' AND "payola_sales"."id" != 1) LIMIT 1
34926
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34927
+  (0.1ms) SAVEPOINT active_record_1
34928
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'op7eu8' AND "payola_sales"."id" != 1) LIMIT 1
34929
+ SQL (0.2ms) UPDATE "payola_sales" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "fee_amount" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["card_expiration", "2013-12-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["fee_amount", 0], ["stripe_customer_id", "test_cus_1"], ["stripe_id", "test_ch_3"], ["updated_at", "2014-11-07 14:31:19.238297"]]
34930
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34931
+  (0.0ms) SAVEPOINT active_record_1
34932
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
34933
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34934
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34935
+  (0.6ms) rollback transaction
34936
+  (0.1ms) begin transaction
34937
+  (0.0ms) SAVEPOINT active_record_1
34938
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-2' LIMIT 1
34939
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.252672"], ["name", "Foo"], ["permalink", "foo-2"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.252672"]]
34940
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34941
+  (0.0ms) SAVEPOINT active_record_1
34942
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34943
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34944
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '72svh2' LIMIT 1
34945
+ SQL (0.4ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.255646"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "72svh2"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.255646"]]
34946
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34947
+  (0.0ms) SAVEPOINT active_record_1
34948
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '72svh2' AND "payola_sales"."id" != 1) LIMIT 1
34949
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34950
+  (0.0ms) SAVEPOINT active_record_1
34951
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '72svh2' AND "payola_sales"."id" != 1) LIMIT 1
34952
+ SQL (0.1ms) UPDATE "payola_sales" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "fee_amount" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["card_expiration", "2013-12-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["fee_amount", 0], ["stripe_customer_id", "test_cus_1"], ["stripe_id", "test_ch_3"], ["updated_at", "2014-11-07 14:31:19.260162"]]
34953
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34954
+  (0.0ms) SAVEPOINT active_record_1
34955
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
34956
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34957
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34958
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34959
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34960
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34961
+  (0.6ms) rollback transaction
34962
+  (0.0ms) begin transaction
34963
+  (0.0ms) SAVEPOINT active_record_1
34964
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-3' LIMIT 1
34965
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.266882"], ["name", "Foo"], ["permalink", "foo-3"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.266882"]]
34966
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34967
+  (0.0ms) SAVEPOINT active_record_1
34968
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34969
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34970
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '3n6act' LIMIT 1
34971
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.269565"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "3n6act"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.269565"]]
34972
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34973
+  (0.0ms) SAVEPOINT active_record_1
34974
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '3n6act' AND "payola_sales"."id" != 1) LIMIT 1
34975
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34976
+  (0.0ms) SAVEPOINT active_record_1
34977
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '3n6act' AND "payola_sales"."id" != 1) LIMIT 1
34978
+ SQL (0.1ms) UPDATE "payola_sales" SET "card_expiration" = ?, "card_last4" = ?, "card_type" = ?, "fee_amount" = ?, "stripe_customer_id" = ?, "stripe_id" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["card_expiration", "2013-12-01"], ["card_last4", "4242"], ["card_type", "Visa"], ["fee_amount", 0], ["stripe_customer_id", "test_cus_1"], ["stripe_id", "test_ch_3"], ["updated_at", "2014-11-07 14:31:19.273347"]]
34979
+  (0.1ms) RELEASE SAVEPOINT active_record_1
34980
+  (0.0ms) SAVEPOINT active_record_1
34981
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
34982
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34983
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
34984
+  (0.8ms) rollback transaction
34985
+  (0.0ms) begin transaction
34986
+  (0.0ms) SAVEPOINT active_record_1
34987
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-4' LIMIT 1
34988
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.280050"], ["name", "Foo"], ["permalink", "foo-4"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.280050"]]
34989
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34990
+  (0.0ms) SAVEPOINT active_record_1
34991
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34992
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
34993
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'hdgl7m' LIMIT 1
34994
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.282618"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "hdgl7m"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.282618"]]
34995
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34996
+  (0.0ms) SAVEPOINT active_record_1
34997
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'hdgl7m' AND "payola_sales"."id" != 1) LIMIT 1
34998
+  (0.0ms) RELEASE SAVEPOINT active_record_1
34999
+  (0.0ms) SAVEPOINT active_record_1
35000
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'hdgl7m' AND "payola_sales"."id" != 1) LIMIT 1
35001
+ SQL (0.1ms) UPDATE "payola_sales" SET "error" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["error", "The card was declined"], ["updated_at", "2014-11-07 14:31:19.285988"]]
35002
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35003
+  (0.0ms) SAVEPOINT active_record_1
35004
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'errored' WHERE "payola_sales"."id" = 1
35005
+  (0.1ms) RELEASE SAVEPOINT active_record_1
35006
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
35007
+  (0.6ms) rollback transaction
35008
+  (0.0ms) begin transaction
35009
+  (0.0ms) SAVEPOINT active_record_1
35010
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-5' LIMIT 1
35011
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.295465"], ["name", "Foo"], ["permalink", "foo-5"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.295465"]]
35012
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35013
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35014
+  (0.4ms) rollback transaction
35015
+  (0.0ms) begin transaction
35016
+ Payola::Sale Exists (0.2ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35017
+  (0.1ms) rollback transaction
35018
+  (0.0ms) begin transaction
35019
+  (0.0ms) SAVEPOINT active_record_1
35020
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-6' LIMIT 1
35021
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.317176"], ["name", "Foo"], ["permalink", "foo-6"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.317176"]]
35022
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35023
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35024
+  (0.4ms) rollback transaction
35025
+  (0.0ms) begin transaction
35026
+  (0.0ms) SAVEPOINT active_record_1
35027
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-7' LIMIT 1
35028
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.322087"], ["name", "Foo"], ["permalink", "foo-7"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.322087"]]
35029
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35030
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35031
+  (0.3ms) rollback transaction
35032
+  (0.1ms) begin transaction
35033
+  (0.0ms) SAVEPOINT active_record_1
35034
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-8' LIMIT 1
35035
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.327238"], ["name", "Foo"], ["permalink", "foo-8"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.327238"]]
35036
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35037
+  (0.0ms) SAVEPOINT active_record_1
35038
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35039
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35040
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'rugoa0' LIMIT 1
35041
+ SQL (0.4ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.330273"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "rugoa0"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.330273"]]
35042
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35043
+  (0.1ms) SAVEPOINT active_record_1
35044
+ SQL (0.2ms) INSERT INTO "owners" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-07 14:31:19.334699"], ["updated_at", "2014-11-07 14:31:19.334699"]]
35045
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35046
+  (0.0ms) SAVEPOINT active_record_1
35047
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'rugoa0' AND "payola_sales"."id" != 1) LIMIT 1
35048
+ SQL (0.1ms) UPDATE "payola_sales" SET "owner_id" = ?, "owner_type" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["owner_id", 1], ["owner_type", "Owner"], ["updated_at", "2014-11-07 14:31:19.338910"]]
35049
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35050
+  (0.6ms) rollback transaction
35051
+  (0.1ms) begin transaction
35052
+  (0.2ms) SAVEPOINT active_record_1
35053
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-9' LIMIT 1
35054
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.381532"], ["name", "Foo"], ["permalink", "foo-9"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.381532"]]
35055
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35056
+  (0.0ms) SAVEPOINT active_record_1
35057
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35058
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35059
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '9g2t60' LIMIT 1
35060
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.384384"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "9g2t60"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.384384"]]
35061
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35062
+  (0.0ms) SAVEPOINT active_record_1
35063
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = '9g2t60' AND "payola_sales"."id" != 1) LIMIT 1
35064
+ SQL (0.1ms) UPDATE "payola_sales" SET "signed_custom_fields" = ?, "updated_at" = ? WHERE "payola_sales"."id" = 1 [["signed_custom_fields", "BAh7BkkiCmZpZWxkBjoGRUZJIgp2YWx1ZQY7AEY=--5d721d50404afc54672ec88747e606e4226813b1fdb826dff62844c014ca61fc"], ["updated_at", "2014-11-07 14:31:19.386255"]]
35065
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35066
+ Payola::Sale Load (0.0ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."id" = ? LIMIT 1 [["id", 1]]
35067
+  (0.7ms) rollback transaction
35068
+  (0.1ms) begin transaction
35069
+  (0.0ms) SAVEPOINT active_record_1
35070
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-10' LIMIT 1
35071
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.391855"], ["name", "Foo"], ["permalink", "foo-10"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.391855"]]
35072
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35073
+  (0.0ms) SAVEPOINT active_record_1
35074
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35075
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35076
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'epr60a' LIMIT 1
35077
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.394545"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "epr60a"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.394545"]]
35078
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35079
+  (0.0ms) SAVEPOINT active_record_1
35080
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'finished' WHERE "payola_sales"."id" = 1
35081
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35082
+  (0.6ms) rollback transaction
35083
+  (0.0ms) begin transaction
35084
+  (0.0ms) SAVEPOINT active_record_1
35085
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-11' LIMIT 1
35086
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.400766"], ["name", "Foo"], ["permalink", "foo-11"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.400766"]]
35087
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35088
+  (0.0ms) SAVEPOINT active_record_1
35089
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35090
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35091
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'qdd3hj' LIMIT 1
35092
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.403493"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "qdd3hj"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.403493"]]
35093
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35094
+  (0.0ms) SAVEPOINT active_record_1
35095
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'processing' WHERE "payola_sales"."id" = 1
35096
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35097
+  (0.6ms) rollback transaction
35098
+  (0.0ms) begin transaction
35099
+  (0.0ms) SAVEPOINT active_record_1
35100
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-12' LIMIT 1
35101
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.408570"], ["name", "Foo"], ["permalink", "foo-12"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.408570"]]
35102
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35103
+  (0.0ms) SAVEPOINT active_record_1
35104
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35105
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35106
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'qq054k' LIMIT 1
35107
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.411151"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "qq054k"], ["product_id", 1], ["product_type", "Product"], ["state", "finished"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.411151"]]
35108
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35109
+  (0.1ms) SAVEPOINT active_record_1
35110
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'refunded' WHERE "payola_sales"."id" = 1
35111
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35112
+  (0.6ms) rollback transaction
35113
+  (0.0ms) begin transaction
35114
+  (0.0ms) SAVEPOINT active_record_1
35115
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-13' LIMIT 1
35116
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.417187"], ["name", "Foo"], ["permalink", "foo-13"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.417187"]]
35117
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35118
+  (0.0ms) SAVEPOINT active_record_1
35119
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35120
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35121
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'prn4ph' LIMIT 1
35122
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.419866"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "prn4ph"], ["product_id", 1], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.419866"]]
35123
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35124
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE ("payola_sales"."guid" = 'prn4ph' AND "payola_sales"."id" != 1) LIMIT 1
35125
+  (0.0ms) SAVEPOINT active_record_1
35126
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-14' LIMIT 1
35127
+ SQL (0.1ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.422935"], ["name", "Foo"], ["permalink", "foo-14"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.422935"]]
35128
+  (0.1ms) RELEASE SAVEPOINT active_record_1
35129
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'prn4ph' LIMIT 1
35130
+  (0.5ms) rollback transaction
35131
+  (0.1ms) begin transaction
35132
+  (0.1ms) SAVEPOINT active_record_1
35133
+ Product Exists (0.2ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-15' LIMIT 1
35134
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.430702"], ["name", "Foo"], ["permalink", "foo-15"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.430702"]]
35135
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35136
+  (0.0ms) SAVEPOINT active_record_1
35137
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35138
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35139
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'ao8ihs' LIMIT 1
35140
+ SQL (0.3ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.433939"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "ao8ihs"], ["product_id", 1], ["product_type", "Product"], ["state", "processing"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.433939"]]
35141
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35142
+  (0.1ms) SAVEPOINT active_record_1
35143
+ SQL (0.1ms) UPDATE "payola_sales" SET "state" = 'errored' WHERE "payola_sales"."id" = 1
35144
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35145
+  (0.8ms) rollback transaction
35146
+  (0.0ms) begin transaction
35147
+  (0.0ms) rollback transaction
35148
+  (0.0ms) begin transaction
35149
+  (0.1ms) SAVEPOINT active_record_1
35150
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-16' LIMIT 1
35151
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.445754"], ["name", "Foo"], ["permalink", "foo-16"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.445754"]]
35152
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35153
+  (0.0ms) SAVEPOINT active_record_1
35154
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-17' LIMIT 1
35155
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.448619"], ["name", "Foo"], ["permalink", "foo-17"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.448619"]]
35156
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35157
+  (0.0ms) SAVEPOINT active_record_1
35158
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35159
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35160
+ Payola::Sale Exists (0.0ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = '8n2u29' LIMIT 1
35161
+ SQL (0.2ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.451235"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "8n2u29"], ["product_id", 2], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.451235"]]
35162
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35163
+ Processing by Payola::TransactionsController#show as HTML
35164
+ Parameters: {"guid"=>"8n2u29"}
35165
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."guid" = '8n2u29' LIMIT 1
35166
+ Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT 1 [["id", 2]]
35167
+ Redirected to http://test.host/
35168
+ Completed 302 Found in 5ms (ActiveRecord: 0.3ms)
35169
+  (0.6ms) rollback transaction
35170
+  (0.0ms) begin transaction
35171
+  (0.0ms) SAVEPOINT active_record_1
35172
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-18' LIMIT 1
35173
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.464251"], ["name", "Foo"], ["permalink", "foo-18"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.464251"]]
35174
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35175
+ Processing by Payola::TransactionsController#status as HTML
35176
+ Parameters: {"guid"=>"doesnotexist"}
35177
+ Payola::Sale Load (0.1ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."guid" = 'doesnotexist' ORDER BY "payola_sales"."id" ASC LIMIT 1
35178
+ Completed 404 Not Found in 12ms (Views: 11.0ms | ActiveRecord: 0.1ms)
35179
+  (0.5ms) rollback transaction
35180
+  (0.1ms) begin transaction
35181
+  (0.0ms) SAVEPOINT active_record_1
35182
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-19' LIMIT 1
35183
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.481588"], ["name", "Foo"], ["permalink", "foo-19"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.481588"]]
35184
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35185
+  (0.0ms) SAVEPOINT active_record_1
35186
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-20' LIMIT 1
35187
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.484060"], ["name", "Foo"], ["permalink", "foo-20"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.484060"]]
35188
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35189
+  (0.0ms) SAVEPOINT active_record_1
35190
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35191
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" IS NULL LIMIT 1
35192
+ Payola::Sale Exists (0.1ms) SELECT 1 AS one FROM "payola_sales" WHERE "payola_sales"."guid" = 'qhrikv' LIMIT 1
35193
+ SQL (0.2ms) INSERT INTO "payola_sales" ("created_at", "currency", "email", "guid", "product_id", "product_type", "state", "stripe_token", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.486961"], ["currency", "usd"], ["email", "test@example.com"], ["guid", "qhrikv"], ["product_id", 2], ["product_type", "Product"], ["state", "pending"], ["stripe_token", "tok_test"], ["updated_at", "2014-11-07 14:31:19.486961"]]
35194
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35195
+ Processing by Payola::TransactionsController#status as HTML
35196
+ Parameters: {"guid"=>"qhrikv"}
35197
+ Payola::Sale Load (0.2ms) SELECT "payola_sales".* FROM "payola_sales" WHERE "payola_sales"."guid" = 'qhrikv' ORDER BY "payola_sales"."id" ASC LIMIT 1
35198
+ Completed 200 OK in 2ms (Views: 0.6ms | ActiveRecord: 0.2ms)
35199
+  (0.6ms) rollback transaction
35200
+  (0.0ms) begin transaction
35201
+  (0.0ms) SAVEPOINT active_record_1
35202
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-21' LIMIT 1
35203
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.495298"], ["name", "Foo"], ["permalink", "foo-21"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.495298"]]
35204
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35205
+ Processing by Payola::TransactionsController#create as HTML
35206
+ Parameters: {"product_class"=>"product", "permalink"=>"foo-21"}
35207
+ Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."permalink" = 'foo-21' LIMIT 1
35208
+ Payola::Coupon Load (0.1ms) SELECT "payola_coupons".* FROM "payola_coupons" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_coupons"."id" ASC LIMIT 1
35209
+ Payola::Affiliate Load (0.1ms) SELECT "payola_affiliates".* FROM "payola_affiliates" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_affiliates"."id" ASC LIMIT 1
35210
+ Completed 200 OK in 8ms (Views: 0.2ms | ActiveRecord: 0.6ms)
35211
+  (0.4ms) rollback transaction
35212
+  (0.0ms) begin transaction
35213
+  (0.0ms) SAVEPOINT active_record_1
35214
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-22' LIMIT 1
35215
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.510476"], ["name", "Foo"], ["permalink", "foo-22"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.510476"]]
35216
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35217
+ Processing by Payola::TransactionsController#create as HTML
35218
+ Parameters: {"product_class"=>"product", "permalink"=>"foo-22"}
35219
+ Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."permalink" = 'foo-22' LIMIT 1
35220
+ Payola::Coupon Load (0.1ms) SELECT "payola_coupons".* FROM "payola_coupons" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_coupons"."id" ASC LIMIT 1
35221
+ Payola::Affiliate Load (0.1ms) SELECT "payola_affiliates".* FROM "payola_affiliates" WHERE (lower(code) = lower(NULL)) ORDER BY "payola_affiliates"."id" ASC LIMIT 1
35222
+ Completed 400 Bad Request in 2ms (Views: 0.2ms | ActiveRecord: 0.3ms)
35223
+  (0.4ms) rollback transaction
35224
+  (0.1ms) begin transaction
35225
+  (0.1ms) rollback transaction
35226
+  (0.1ms) begin transaction
35227
+  (0.1ms) rollback transaction
35228
+  (0.1ms) begin transaction
35229
+  (0.1ms) rollback transaction
35230
+  (0.1ms) begin transaction
35231
+  (0.1ms) rollback transaction
35232
+  (0.1ms) begin transaction
35233
+  (0.1ms) rollback transaction
35234
+  (0.1ms) begin transaction
35235
+  (0.1ms) rollback transaction
35236
+  (0.0ms) begin transaction
35237
+  (0.0ms) rollback transaction
35238
+  (0.0ms) begin transaction
35239
+  (0.0ms) rollback transaction
35240
+  (0.0ms) begin transaction
35241
+  (0.0ms) rollback transaction
35242
+  (0.0ms) begin transaction
35243
+ Payola::StripeWebhook Exists (0.1ms) SELECT 1 AS one FROM "payola_stripe_webhooks" WHERE "payola_stripe_webhooks"."stripe_id" = 'test_id' LIMIT 1
35244
+  (0.1ms) rollback transaction
35245
+  (0.0ms) begin transaction
35246
+  (0.0ms) SAVEPOINT active_record_1
35247
+ Payola::StripeWebhook Exists (0.1ms) SELECT 1 AS one FROM "payola_stripe_webhooks" WHERE "payola_stripe_webhooks"."stripe_id" = 'test_id' LIMIT 1
35248
+ SQL (0.2ms) INSERT INTO "payola_stripe_webhooks" ("created_at", "stripe_id", "updated_at") VALUES (?, ?, ?) [["created_at", "2014-11-07 14:31:19.593492"], ["stripe_id", "test_id"], ["updated_at", "2014-11-07 14:31:19.593492"]]
35249
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35250
+ Payola::StripeWebhook Exists (0.1ms) SELECT 1 AS one FROM "payola_stripe_webhooks" WHERE "payola_stripe_webhooks"."stripe_id" = 'test_id' LIMIT 1
35251
+  (0.4ms) rollback transaction
35252
+  (0.0ms) begin transaction
35253
+  (0.0ms) rollback transaction
35254
+  (0.0ms) begin transaction
35255
+  (0.1ms) rollback transaction
35256
+  (0.0ms) begin transaction
35257
+  (0.0ms) SAVEPOINT active_record_1
35258
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-23' LIMIT 1
35259
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.600196"], ["name", "Foo"], ["permalink", "foo-23"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.600196"]]
35260
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35261
+  (0.4ms) rollback transaction
35262
+  (0.0ms) begin transaction
35263
+  (0.0ms) SAVEPOINT active_record_1
35264
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-24' LIMIT 1
35265
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.603914"], ["name", "Foo"], ["permalink", "foo-24"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.603914"]]
35266
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35267
+  (0.1ms) SAVEPOINT active_record_1
35268
+ Payola::Affiliate Exists (0.1ms) SELECT 1 AS one FROM "payola_affiliates" WHERE "payola_affiliates"."code" = 'MyString' LIMIT 1
35269
+ SQL (0.3ms) INSERT INTO "payola_affiliates" ("code", "created_at", "email", "percent", "updated_at") VALUES (?, ?, ?, ?, ?) [["code", "MyString"], ["created_at", "2014-11-07 14:31:19.610603"], ["email", "foo@example.com"], ["percent", 100], ["updated_at", "2014-11-07 14:31:19.610603"]]
35270
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35271
+ Payola::Affiliate Load (0.2ms) SELECT "payola_affiliates".* FROM "payola_affiliates" WHERE "payola_affiliates"."id" = ? LIMIT 1 [["id", 1]]
35272
+  (0.7ms) rollback transaction
35273
+  (0.1ms) begin transaction
35274
+  (0.0ms) SAVEPOINT active_record_1
35275
+ Product Exists (0.1ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-25' LIMIT 1
35276
+ SQL (0.2ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.620405"], ["name", "Foo"], ["permalink", "foo-25"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.620405"]]
35277
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35278
+  (0.1ms) SAVEPOINT active_record_1
35279
+ Payola::Coupon Exists (0.1ms) SELECT 1 AS one FROM "payola_coupons" WHERE "payola_coupons"."code" = 'MyString' LIMIT 1
35280
+ SQL (0.3ms) INSERT INTO "payola_coupons" ("code", "created_at", "percent_off", "updated_at") VALUES (?, ?, ?, ?) [["code", "MyString"], ["created_at", "2014-11-07 14:31:19.626612"], ["percent_off", 1], ["updated_at", "2014-11-07 14:31:19.626612"]]
35281
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35282
+  (0.6ms) rollback transaction
35283
+  (0.1ms) begin transaction
35284
+  (0.1ms) SAVEPOINT active_record_1
35285
+ Product Exists (0.2ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-26' LIMIT 1
35286
+ SQL (0.3ms) INSERT INTO "products" ("created_at", "name", "permalink", "price", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-07 14:31:19.634069"], ["name", "Foo"], ["permalink", "foo-26"], ["price", 100], ["updated_at", "2014-11-07 14:31:19.634069"]]
35287
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35288
+  (0.0ms) SAVEPOINT active_record_1
35289
+ Payola::Coupon Exists (0.0ms) SELECT 1 AS one FROM "payola_coupons" WHERE "payola_coupons"."code" = 'MyString' LIMIT 1
35290
+ SQL (0.2ms) INSERT INTO "payola_coupons" ("code", "created_at", "percent_off", "updated_at") VALUES (?, ?, ?, ?) [["code", "MyString"], ["created_at", "2014-11-07 14:31:19.636213"], ["percent_off", 1], ["updated_at", "2014-11-07 14:31:19.636213"]]
35291
+  (0.0ms) RELEASE SAVEPOINT active_record_1
35292
+  (0.4ms) rollback transaction
35293
+  (0.1ms) begin transaction
35294
+  (0.1ms) rollback transaction
35295
+  (0.0ms) begin transaction
35296
+  (0.0ms) rollback transaction
35297
+  (0.0ms) begin transaction
35298
+  (0.0ms) rollback transaction
35299
+  (0.1ms) begin transaction
35300
+ Product Exists (0.2ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'f' LIMIT 1
35301
+  (0.1ms) rollback transaction
35302
+  (0.1ms) begin transaction
35303
+ Product Exists (0.2ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-28' LIMIT 1
35304
+  (0.1ms) rollback transaction
35305
+  (0.1ms) begin transaction
35306
+ Product Exists (0.2ms) SELECT 1 AS one FROM "products" WHERE "products"."permalink" = 'foo-29' LIMIT 1
35307
+  (0.1ms) rollback transaction
35308
+  (0.1ms) begin transaction
35309
+  (0.0ms) rollback transaction
35310
+  (0.0ms) begin transaction
35311
+  (0.1ms) rollback transaction
35312
+  (0.1ms) begin transaction
35313
+  (0.0ms) rollback transaction
35314
+  (0.0ms) begin transaction
35315
+  (0.0ms) rollback transaction
35316
+  (0.0ms) begin transaction
35317
+  (0.0ms) rollback transaction
35318
+  (0.0ms) begin transaction
35319
+  (0.0ms) rollback transaction
35320
+  (0.0ms) begin transaction
35321
+  (0.1ms) rollback transaction
35322
+  (0.0ms) begin transaction
35323
+  (0.0ms) rollback transaction
35324
+  (0.0ms) begin transaction
35325
+  (0.0ms) rollback transaction
35326
+  (0.0ms) begin transaction
35327
+  (0.0ms) rollback transaction
35328
+  (0.0ms) begin transaction
35329
+  (0.0ms) rollback transaction
35330
+  (0.0ms) begin transaction
35331
+  (0.1ms) rollback transaction