espinita 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3f64c8486873224f8ea43e9de6608157eb0b3506
4
- data.tar.gz: aa1acd66ad543d6a2d03a8a0ecb2f5b1b0ac60a4
3
+ metadata.gz: 234b680ecbdfb3988ce978738780d361d2bffd66
4
+ data.tar.gz: 97dec308b5d32d4921b1ee23af9dad9c02ad44c3
5
5
  SHA512:
6
- metadata.gz: 4a22f120c9e0cedcc01906b2c91af2fe8b96a08b53b8fdb03894e43cd4b90549a79cd58f4b373abb9c1c0a92dd0c2293556838be9ac39b49b925819ad7ddd0d6
7
- data.tar.gz: fb0c9e49dfd0944d62d901f1f0adad0a34dc445346203b7ea480cbc78820059207de22144cf89d8b488ce03ef0f2dfc35125b6e63369bcba9ed8c2ced3e69731
6
+ metadata.gz: 8bd2f0db7a08c4934b3c0525334672f2eb8f6d923f1f2338d21ec8276fa3322c79353db33463bc36e732a5d974aa902795712380177a150ab7050da60e46a957
7
+ data.tar.gz: a65fa34e55cbf5c8dd41cbc5802a4ca8c9aaa33282a5bfad0034d05a5a591acc6981e99cf4eb95d67938816284fcbc0e7d15430aaea1b05661d0acff024be620
data/README.md CHANGED
@@ -17,7 +17,7 @@ In your gemfile
17
17
 
18
18
  ```ruby
19
19
  gem "espinita"
20
- ``
20
+ ```
21
21
 
22
22
  In console
23
23
  ```ruby
@@ -74,3 +74,48 @@ Espinita will detect the current user when records saved from rails controllers.
74
74
  ```ruby
75
75
  Espinita.current_user_method = :authenticated_user
76
76
  ```
77
+
78
+ #### History and Restoration
79
+ If you just want a summary of changes for a particular attribute or attributes of a model, you can use the `history_from_audits_for` method.
80
+ ```ruby
81
+ my_model.history_from_audits_for(:name)
82
+ => [{changes: {name: "Arglebargle"}, changed_at: 2015-05-13 15:28:22 -0700},
83
+ {changes: {name: "Baz"}, changed_at: 2014-05-13 15:28:22 -0700},
84
+ {changes: {name: "Foo"}, changed_at: 2013-05-13 15:28:22 -0700}]
85
+
86
+ ```
87
+
88
+ You can also provide an array of attributes to get a single history for all of them.
89
+ ```ruby
90
+ my_model.history_from_audits_for([:name, :settings])
91
+ => [{changes: {name: "Arglebargle", settings: "Waffles"}, changed_at: 2015-05-13 15:28:22 -0700},
92
+ {changes: {name: "Baz"}, changed_at: 2014-05-13 15:28:22 -0700}]
93
+
94
+ ```
95
+
96
+ Sometimes it's useful to roll a record back to a particular point in time, such as if it was accidentally modified. For this, the `restore_attributes!` method is provided.
97
+
98
+ As with `history_from_audits_for`, this can be used with a single attribute or an array of attributes.
99
+ ```ruby
100
+ model.name
101
+ => "Baz"
102
+ model.settings
103
+ => ""
104
+
105
+ model.history_from_audits_for([:name, :settings])
106
+ => [{:changes=>{:name=>"Baz", :settings=>""}, :changed_at=>2015-05-03 15:33:58 -0700},
107
+ {:changes=>{:name=>"Arglebargle", :settings=>"IHOP"}, :changed_at=>2015-03-24 15:33:58 -0700},
108
+ {:changes=>{:name=>"Walrus"}, :changed_at=>2014-05-13 15:33:58 -0700}]
109
+
110
+ model.restore_attributes!([:name, :settings], DateTime.now - 57.days)
111
+ => true
112
+
113
+ model.name
114
+ => "Walrus"
115
+ model.settings
116
+ => "MyText"
117
+ ```
118
+
119
+ The `restore_attributes!` method returns `true` if it makes a change to the model, or `false` if there is no resulting change.
120
+
121
+ Note: this uses `update_attributes()` to do the rollback, so it will *skip* validations, but will trigger any callbacks that you may have in place.
@@ -40,7 +40,7 @@ module Espinita
40
40
 
41
41
  end
42
42
 
43
- def permited_columns
43
+ def permitted_columns
44
44
  self.column_names - self.excluded_cols.to_a
45
45
  end
46
46
 
@@ -56,9 +56,65 @@ module Espinita
56
56
 
57
57
  end
58
58
 
59
- # audited attributes detected against permited columns
59
+ def history_from_audits_for(attributes)
60
+ attributes = arrayify(attributes)
61
+ attributes = attributes.map(&:to_s) # for consistency, ensure that we're working with strings, not symbols
62
+ raise ArgumentError, "At least one of the specified columns does not exist or is not audited." if (attributes - self.class.permitted_columns).any?
63
+
64
+ audits = relevant_audits(self.audits, attributes)
65
+
66
+ property_history = audits.map do |a|
67
+ {
68
+ changes: Hash[
69
+ (a.audited_changes.keys.map(&:to_s) & attributes).map do |key|
70
+ [key.to_sym, a.audited_changes[key.to_sym].last]
71
+ end
72
+ ],
73
+ changed_at: a.created_at.localtime
74
+ }
75
+ end
76
+ return property_history
77
+ end
78
+
79
+ def restore_attributes!(attributes, datetime)
80
+ attributes = arrayify(attributes)
81
+ attributes = attributes.map(&:to_s) # for consistency, ensure that we're working with strings, not symbols
82
+ raise ArgumentError, "At least one of the specified columns does not exist or is not audited." if (attributes - self.class.permitted_columns).any?
83
+
84
+ changes = {}
85
+
86
+ attributes.each do |attrib|
87
+ audits = relevant_audits(self.audits, [attrib])
88
+ audit = audits.select{ |a| a.created_at < datetime }.first
89
+
90
+ if audit.present? # restore to the requested point in time
91
+ restore_val = audit.audited_changes[attrib.to_sym].last
92
+ else # or fall back to the initial state of the record if the requested time predates the first audit
93
+ restore_val = audits.last.audited_changes[attrib.to_sym].first
94
+ end
95
+
96
+ unless restore_val == self[attrib]
97
+ changes[attrib] = restore_val
98
+ end
99
+ end
100
+
101
+ self.update_attributes(changes)
102
+ return changes.keys.count > 0
103
+ end
104
+
105
+ def restore_to_audit(id_or_record)
106
+ audit = self.audits.find(id_or_record)
107
+
108
+ audit.ancestors.each do |ancestor|
109
+ self.assign_attributes Hash[ancestor.audited_changes.map{ |k,v| [k,v[0]] }]
110
+ end
111
+
112
+ self.save
113
+ end
114
+
115
+ # audited attributes detected against permitted columns
60
116
  def audited_attributes
61
- self.changes.keys & self.class.permited_columns
117
+ self.changes.keys & self.class.permitted_columns
62
118
  end
63
119
 
64
120
  def audited_hash
@@ -91,5 +147,21 @@ module Espinita
91
147
  self.audits.create(options) unless options[:audited_changes].blank?
92
148
  end
93
149
 
150
+ private
151
+
152
+ def arrayify(item_or_array) # convert single attributes to arrays [:myProp]
153
+ if item_or_array.is_a?(Array)
154
+ return item_or_array
155
+ else
156
+ return Array(item_or_array)
157
+ end
158
+ end
159
+
160
+ def relevant_audits(audits, attributes)
161
+ audits
162
+ .order('created_at DESC') # most recent first
163
+ .select{ |a| attributes.any?{ |p| a.audited_changes.key?(p.to_sym) } }
164
+ end
165
+
94
166
  end
95
167
  end
@@ -1,3 +1,3 @@
1
1
  module Espinita
2
- VERSION = "0.0.8"
2
+ VERSION = "0.0.9"
3
3
  end
@@ -9130,3 +9130,425 @@ Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 0.6ms)
9130
9130
  SQL (0.1ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "destroy"], ["auditable_id", 14], ["auditable_type", "GeneralModel"], ["audited_changes", "---\nid: 14\nuser_id: \nname: MyString\nsettings: MyText\nposition: 1\ncreated_at: 2014-08-03 01:19:02.855004000 Z\nupdated_at: 2014-08-03 01:19:02.855004000 Z\n"], ["comment", "deleted model 14: "], ["created_at", "2014-08-03 01:19:02.859009"], ["remote_address", "0.0.0.0"], ["updated_at", "2014-08-03 01:19:02.859009"], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9131
9131
  SQL (0.1ms) DELETE FROM "general_models" WHERE "general_models"."id" = ? [["id", 14]]
9132
9132
   (0.1ms) commit transaction
9133
+  (0.5ms) CREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "last_name" varchar(255), "email" varchar(255), "created_at" datetime, "updated_at" datetime) 
9134
+  (0.3ms) CREATE TABLE "general_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "user_id" integer, "name" varchar(255), "settings" text, "position" integer, "created_at" datetime, "updated_at" datetime)
9135
+  (0.2ms) CREATE INDEX "index_general_models_on_user_id" ON "general_models" ("user_id")
9136
+  (0.2ms) CREATE TABLE "espinita_audits" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "auditable_id" integer, "auditable_type" varchar(255), "user_id" integer, "user_type" varchar(255), "audited_changes" text, "comment" varchar(255), "version" integer, "action" varchar(255), "remote_address" varchar(255), "created_at" datetime, "updated_at" datetime)
9137
+  (0.2ms) CREATE INDEX "index_espinita_audits_on_auditable_id_and_auditable_type" ON "espinita_audits" ("auditable_id", "auditable_type")
9138
+  (0.2ms) CREATE INDEX "index_espinita_audits_on_user_id_and_user_type" ON "espinita_audits" ("user_id", "user_type")
9139
+  (15.7ms) DELETE FROM "users";
9140
+  (0.2ms) SELECT name FROM sqlite_master WHERE type='table' AND name='sqlite_sequence';
9141
+  (0.1ms) DELETE FROM sqlite_sequence where name = 'users';
9142
+  (0.1ms) DELETE FROM "general_models";
9143
+  (0.1ms) SELECT name FROM sqlite_master WHERE type='table' AND name='sqlite_sequence';
9144
+  (0.1ms) DELETE FROM sqlite_sequence where name = 'general_models';
9145
+  (0.1ms) DELETE FROM "espinita_audits";
9146
+  (0.1ms) SELECT name FROM sqlite_master WHERE type='table' AND name='sqlite_sequence';
9147
+  (0.1ms) DELETE FROM sqlite_sequence where name = 'espinita_audits';
9148
+  (0.1ms) begin transaction
9149
+ SQL (2.9ms) INSERT INTO "users" ("created_at", "email", "last_name", "name", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["email", "john@afferson.com"], ["last_name", "Afferson"], ["name", "John"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9150
+  (0.1ms) commit transaction
9151
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits"
9152
+ Processing by AuditsController#audit as HTML
9153
+  (0.1ms) begin transaction
9154
+ SQL (0.3ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9155
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 1 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9156
+ SQL (0.4ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 1], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- \n- MyString\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 1\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["user_id", 1], ["user_type", "User"], ["version", 1]]
9157
+ SQL (0.2ms) UPDATE "espinita_audits" SET "updated_at" = ?, "audited_changes" = ? WHERE "espinita_audits"."id" = 1 [["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["audited_changes", "---\n:name:\n- \n- MyString\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 1\n"]]
9158
+  (0.1ms) commit transaction
9159
+ Rendered text template (0.0ms)
9160
+ Completed 200 OK in 74ms (Views: 6.2ms | ActiveRecord: 1.6ms)
9161
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits"
9162
+ Espinita::Audit Load (0.2ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 1], ["auditable_type", "GeneralModel"]]
9163
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 1]]
9164
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 1], ["auditable_type", "GeneralModel"]]
9165
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits"
9166
+ Processing by AuditsController#audit as HTML
9167
+  (0.1ms) begin transaction
9168
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9169
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 2 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9170
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 2], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- \n- MyString\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 2\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9171
+  (0.1ms) commit transaction
9172
+ Completed 200 OK in 7ms (Views: 0.3ms | ActiveRecord: 0.7ms)
9173
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits"
9174
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 2], ["auditable_type", "GeneralModel"]]
9175
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 2], ["auditable_type", "GeneralModel"]]
9176
+  (0.1ms) begin transaction
9177
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9178
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 3 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9179
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 3], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 3\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9180
+  (0.1ms) commit transaction
9181
+  (0.1ms) begin transaction
9182
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 3 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9183
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 3], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 2]]
9184
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 3 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9185
+  (0.1ms) commit transaction
9186
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 3], ["auditable_type", "GeneralModel"]]
9187
+  (0.1ms) begin transaction
9188
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9189
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 4 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9190
+ SQL (0.3ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 4], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- \n- MyString\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9191
+  (0.1ms) commit transaction
9192
+  (0.1ms) begin transaction
9193
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 4 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9194
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 4], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 2]]
9195
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 4 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9196
+  (0.1ms) commit transaction
9197
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 4], ["auditable_type", "GeneralModel"]]
9198
+  (0.1ms) begin transaction
9199
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9200
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 5 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9201
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 5], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- \n- MyString\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9202
+  (0.1ms) commit transaction
9203
+  (0.1ms) begin transaction
9204
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 5 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9205
+  (0.1ms) commit transaction
9206
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 5], ["auditable_type", "GeneralModel"]]
9207
+  (0.1ms) begin transaction
9208
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9209
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 6 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9210
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 6], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 6\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9211
+  (0.1ms) commit transaction
9212
+  (0.1ms) begin transaction
9213
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 6 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9214
+  (0.1ms) commit transaction
9215
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 6], ["auditable_type", "GeneralModel"]]
9216
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" ASC LIMIT 1 [["auditable_id", 6], ["auditable_type", "GeneralModel"]]
9217
+  (0.1ms) begin transaction
9218
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9219
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 7 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9220
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 7], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 7\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9221
+  (0.1ms) commit transaction
9222
+  (0.1ms) begin transaction
9223
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 7 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9224
+  (0.1ms) commit transaction
9225
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 7], ["auditable_type", "GeneralModel"]]
9226
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 7], ["auditable_type", "GeneralModel"]]
9227
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 7], ["auditable_type", "GeneralModel"]]
9228
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 7], ["auditable_type", "GeneralModel"]]
9229
+  (0.1ms) begin transaction
9230
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9231
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 8 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9232
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 8], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 8\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9233
+  (0.1ms) commit transaction
9234
+  (0.1ms) begin transaction
9235
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 8 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9236
+ SQL (0.4ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 8], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 2]]
9237
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 8 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9238
+  (0.1ms) commit transaction
9239
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 8], ["auditable_type", "GeneralModel"]]
9240
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 8], ["auditable_type", "GeneralModel"]]
9241
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 8], ["auditable_type", "GeneralModel"]]
9242
+  (0.1ms) begin transaction
9243
+ SQL (0.3ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9244
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 9 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9245
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 9], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- \n- MyString\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 9\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 1]]
9246
+  (0.1ms) commit transaction
9247
+  (0.1ms) begin transaction
9248
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 9 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9249
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 9], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["version", 2]]
9250
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 9 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9251
+  (0.1ms) commit transaction
9252
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 9], ["auditable_type", "GeneralModel"]]
9253
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 9], ["auditable_type", "GeneralModel"]]
9254
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 9], ["auditable_type", "GeneralModel"]]
9255
+  (0.1ms) begin transaction
9256
+ SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "last_name", "name", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["email", "john@afferson.com"], ["last_name", "Afferson"], ["name", "John"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9257
+  (0.1ms) commit transaction
9258
+  (0.1ms) begin transaction
9259
+ SQL (0.1ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9260
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 10 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9261
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 10], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- \n- MyString\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 10\n"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9262
+  (0.1ms) commit transaction
9263
+  (0.1ms) begin transaction
9264
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 10 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9265
+ SQL (0.3ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 10], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9266
+ SQL (0.1ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 10 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9267
+  (0.1ms) commit transaction
9268
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 10], ["auditable_type", "GeneralModel"]]
9269
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 2]]
9270
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 10], ["auditable_type", "GeneralModel"]]
9271
+ User Load (0.0ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 2]]
9272
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 10], ["auditable_type", "GeneralModel"]]
9273
+ User Load (0.0ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 2]]
9274
+  (0.1ms) begin transaction
9275
+ SQL (0.3ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9276
+  (0.1ms) commit transaction
9277
+  (0.1ms) begin transaction
9278
+ SQL (0.2ms) UPDATE "general_models" SET "updated_at" = ? WHERE "general_models"."id" = 11 [["updated_at", Mon, 25 May 2015 00:59:38 UTC +00:00]]
9279
+  (0.1ms) commit transaction
9280
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 11], ["auditable_type", "GeneralModel"]]
9281
+  (0.1ms) begin transaction
9282
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:38 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:38 UTC +00:00]]
9283
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 12 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9284
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "create"], ["auditable_id", 12], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- \n- MyString\n:settings:\n- \n- MyText\n:position:\n- \n- 1\n:id:\n- \n- 12\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9285
+  (0.1ms) commit transaction
9286
+  (0.1ms) begin transaction
9287
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 12 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9288
+  (0.1ms) commit transaction
9289
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 12], ["auditable_type", "GeneralModel"]]
9290
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 12], ["auditable_type", "GeneralModel"]]
9291
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 12], ["auditable_type", "GeneralModel"]]
9292
+  (0.1ms) begin transaction
9293
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9294
+  (0.1ms) commit transaction
9295
+  (0.0ms) begin transaction
9296
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 13 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9297
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 13], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9298
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 13 [["name", "Foo"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9299
+  (0.1ms) commit transaction
9300
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 13], ["auditable_type", "GeneralModel"]]
9301
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 13], ["auditable_type", "GeneralModel"]]
9302
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" DESC LIMIT 1 [["auditable_id", 13], ["auditable_type", "GeneralModel"]]
9303
+  (0.1ms) begin transaction
9304
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9305
+  (0.1ms) commit transaction
9306
+  (0.1ms) SELECT COUNT(*) FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? [["auditable_id", 14], ["auditable_type", "GeneralModel"]]
9307
+  (0.1ms) begin transaction
9308
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 14 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9309
+ SQL (0.3ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "destroy"], ["auditable_id", 14], ["auditable_type", "GeneralModel"], ["audited_changes", "---\nid: 14\nuser_id: \nname: MyString\nsettings: MyText\nposition: 1\ncreated_at: &1 2015-05-24 00:59:39.020516000 Z\nupdated_at: *1\n"], ["comment", "deleted model 14: "], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9310
+ SQL (0.1ms) DELETE FROM "general_models" WHERE "general_models"."id" = ? [["id", 14]]
9311
+  (0.1ms) commit transaction
9312
+  (0.0ms) begin transaction
9313
+ SQL (0.0ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9314
+  (0.0ms) commit transaction
9315
+  (0.0ms) begin transaction
9316
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 15 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9317
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 15], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9318
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ? WHERE "general_models"."id" = 15 [["name", "Foo"]]
9319
+  (0.0ms) commit transaction
9320
+  (0.0ms) begin transaction
9321
+ SQL (0.0ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9322
+  (0.0ms) commit transaction
9323
+  (0.0ms) begin transaction
9324
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 16 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9325
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 16], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9326
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ? WHERE "general_models"."id" = 16 [["name", "Foo"]]
9327
+  (0.0ms) commit transaction
9328
+ Espinita::Audit Load (0.0ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 16], ["auditable_type", "GeneralModel"]]
9329
+  (0.0ms) begin transaction
9330
+ SQL (0.0ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9331
+  (0.0ms) commit transaction
9332
+  (0.0ms) begin transaction
9333
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 17 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9334
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 17], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9335
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ? WHERE "general_models"."id" = 17 [["name", "Foo"]]
9336
+  (0.0ms) commit transaction
9337
+ Espinita::Audit Load (0.0ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 17], ["auditable_type", "GeneralModel"]]
9338
+  (0.0ms) begin transaction
9339
+ SQL (0.0ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9340
+  (0.0ms) commit transaction
9341
+  (0.0ms) begin transaction
9342
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 18 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9343
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 18], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9344
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ? WHERE "general_models"."id" = 18 [["name", "Foo"]]
9345
+  (0.0ms) commit transaction
9346
+  (0.0ms) begin transaction
9347
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 18 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9348
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 18], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Foo\n- Baz\n"], ["comment", "Some comment"], ["created_at", Wed, 03 Jun 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Wed, 03 Jun 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9349
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 18 [["name", "Baz"], ["updated_at", Wed, 03 Jun 2015 00:59:39 UTC +00:00]]
9350
+  (0.0ms) commit transaction
9351
+  (0.0ms) begin transaction
9352
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 18 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9353
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 18], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Baz\n- Arglebargle\n"], ["comment", "Some comment"], ["created_at", Tue, 24 May 2016 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Tue, 24 May 2016 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9354
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 18 [["name", "Arglebargle"], ["updated_at", Tue, 24 May 2016 00:59:39 UTC +00:00]]
9355
+  (0.0ms) commit transaction
9356
+ Espinita::Audit Load (0.0ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 18], ["auditable_type", "GeneralModel"]]
9357
+  (0.0ms) begin transaction
9358
+ SQL (0.0ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9359
+  (0.0ms) commit transaction
9360
+  (0.0ms) begin transaction
9361
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 19 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9362
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 19], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9363
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ? WHERE "general_models"."id" = 19 [["name", "Foo"]]
9364
+  (0.0ms) commit transaction
9365
+  (0.0ms) begin transaction
9366
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 19 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9367
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 19], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Foo\n- Baz\n:position:\n- 1\n- 42\n"], ["comment", "Some comment"], ["created_at", Wed, 03 Jun 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Wed, 03 Jun 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9368
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 19 [["name", "Baz"], ["position", 42], ["updated_at", Wed, 03 Jun 2015 00:59:39 UTC +00:00]]
9369
+  (0.0ms) commit transaction
9370
+  (0.0ms) begin transaction
9371
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 19 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9372
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 19], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Baz\n- Arglebargle\n:settings:\n- MyText\n- Waffles\n"], ["comment", "Some comment"], ["created_at", Tue, 24 May 2016 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Tue, 24 May 2016 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9373
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 19 [["name", "Arglebargle"], ["settings", "Waffles"], ["updated_at", Tue, 24 May 2016 00:59:39 UTC +00:00]]
9374
+  (0.0ms) commit transaction
9375
+ Espinita::Audit Load (0.0ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 19], ["auditable_type", "GeneralModel"]]
9376
+ Espinita::Audit Load (0.0ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 19], ["auditable_type", "GeneralModel"]]
9377
+  (0.1ms) begin transaction
9378
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9379
+  (0.1ms) commit transaction
9380
+  (0.0ms) begin transaction
9381
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 20 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9382
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 20], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Walrus\n"], ["comment", "Some comment"], ["created_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9383
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 20 [["name", "Walrus"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00]]
9384
+  (0.0ms) commit transaction
9385
+  (0.0ms) begin transaction
9386
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 20 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9387
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 20], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Walrus\n- Arglebargle\n:settings:\n- MyText\n- IHOP\n:position:\n- 1\n- 2\n"], ["comment", "Some comment"], ["created_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9388
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 20 [["name", "Arglebargle"], ["settings", "IHOP"], ["position", 2], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00]]
9389
+  (0.0ms) commit transaction
9390
+  (0.0ms) begin transaction
9391
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 20 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9392
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 20], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Arglebargle\n- Baz\n:settings:\n- IHOP\n- ''\n:position:\n- 2\n- \n"], ["comment", "Some comment"], ["created_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9393
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 20 [["name", "Baz"], ["settings", ""], ["position", nil], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00]]
9394
+  (0.0ms) commit transaction
9395
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 20], ["auditable_type", "GeneralModel"]]
9396
+  (0.1ms) begin transaction
9397
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 20 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9398
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 20], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Baz\n- Arglebargle\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 4]]
9399
+ SQL (0.1ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 20 [["name", "Arglebargle"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9400
+  (0.1ms) commit transaction
9401
+  (0.1ms) begin transaction
9402
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9403
+  (0.1ms) commit transaction
9404
+  (0.0ms) begin transaction
9405
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 21 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9406
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 21], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Walrus\n"], ["comment", "Some comment"], ["created_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9407
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 21 [["name", "Walrus"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00]]
9408
+  (0.0ms) commit transaction
9409
+  (0.0ms) begin transaction
9410
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 21 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9411
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 21], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Walrus\n- Arglebargle\n:settings:\n- MyText\n- IHOP\n:position:\n- 1\n- 2\n"], ["comment", "Some comment"], ["created_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9412
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 21 [["name", "Arglebargle"], ["settings", "IHOP"], ["position", 2], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00]]
9413
+  (0.0ms) commit transaction
9414
+  (0.0ms) begin transaction
9415
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 21 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9416
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 21], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Arglebargle\n- Baz\n:settings:\n- IHOP\n- ''\n:position:\n- 2\n- \n"], ["comment", "Some comment"], ["created_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9417
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 21 [["name", "Baz"], ["settings", ""], ["position", nil], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00]]
9418
+  (0.0ms) commit transaction
9419
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 21], ["auditable_type", "GeneralModel"]]
9420
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 21], ["auditable_type", "GeneralModel"]]
9421
+  (0.1ms) begin transaction
9422
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 21 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9423
+ SQL (0.4ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 21], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Baz\n- Walrus\n:settings:\n- ''\n- MyText\n"], ["comment", "Some comment"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 4]]
9424
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 21 [["name", "Walrus"], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9425
+  (0.1ms) commit transaction
9426
+  (0.1ms) begin transaction
9427
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9428
+  (0.1ms) commit transaction
9429
+  (0.0ms) begin transaction
9430
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 22 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9431
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 22], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Walrus\n"], ["comment", "Some comment"], ["created_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9432
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 22 [["name", "Walrus"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00]]
9433
+  (0.0ms) commit transaction
9434
+  (0.0ms) begin transaction
9435
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 22 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9436
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 22], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Walrus\n- Arglebargle\n:settings:\n- MyText\n- IHOP\n:position:\n- 1\n- 2\n"], ["comment", "Some comment"], ["created_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9437
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 22 [["name", "Arglebargle"], ["settings", "IHOP"], ["position", 2], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00]]
9438
+  (0.0ms) commit transaction
9439
+  (0.0ms) begin transaction
9440
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 22 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9441
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 22], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Arglebargle\n- Baz\n:settings:\n- IHOP\n- ''\n:position:\n- 2\n- \n"], ["comment", "Some comment"], ["created_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9442
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 22 [["name", "Baz"], ["settings", ""], ["position", nil], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00]]
9443
+  (0.0ms) commit transaction
9444
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY created_at DESC [["auditable_id", 22], ["auditable_type", "GeneralModel"]]
9445
+  (0.1ms) begin transaction
9446
+  (0.1ms) commit transaction
9447
+  (0.1ms) begin transaction
9448
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9449
+  (0.1ms) commit transaction
9450
+  (0.0ms) begin transaction
9451
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 23 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9452
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 23], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Walrus\n"], ["comment", "Some comment"], ["created_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9453
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "updated_at" = ? WHERE "general_models"."id" = 23 [["name", "Walrus"], ["updated_at", Sat, 24 May 2014 00:59:39 UTC +00:00]]
9454
+  (0.0ms) commit transaction
9455
+  (0.0ms) begin transaction
9456
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 23 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9457
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 23], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Walrus\n- Arglebargle\n:settings:\n- MyText\n- IHOP\n:position:\n- 1\n- 2\n"], ["comment", "Some comment"], ["created_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9458
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 23 [["name", "Arglebargle"], ["settings", "IHOP"], ["position", 2], ["updated_at", Sat, 04 Apr 2015 00:59:39 UTC +00:00]]
9459
+  (0.0ms) commit transaction
9460
+  (0.0ms) begin transaction
9461
+  (0.0ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 23 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9462
+ SQL (0.0ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 23], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Arglebargle\n- Baz\n:settings:\n- IHOP\n- ''\n:position:\n- 2\n- \n"], ["comment", "Some comment"], ["created_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9463
+ SQL (0.0ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 23 [["name", "Baz"], ["settings", ""], ["position", nil], ["updated_at", Thu, 14 May 2015 00:59:39 UTC +00:00]]
9464
+  (0.0ms) commit transaction
9465
+  (0.3ms) begin transaction
9466
+ SQL (0.4ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9467
+  (0.1ms) commit transaction
9468
+  (0.1ms) begin transaction
9469
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 24 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9470
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 24], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Ringo\n:settings:\n- MyText\n- Walrus\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9471
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 24 [["name", "Ringo"], ["settings", "Walrus"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9472
+  (0.1ms) commit transaction
9473
+  (0.1ms) begin transaction
9474
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 24 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9475
+ SQL (0.3ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 24], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:position:\n- 1\n- 7\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9476
+ SQL (0.2ms) UPDATE "general_models" SET "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 24 [["position", 7], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9477
+  (0.1ms) commit transaction
9478
+  (0.1ms) begin transaction
9479
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 24 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9480
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 24], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:position:\n- 7\n- 3\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9481
+ SQL (0.1ms) UPDATE "general_models" SET "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 24 [["position", 3], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9482
+  (0.1ms) commit transaction
9483
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" ASC LIMIT 1 [["auditable_id", 24], ["auditable_type", "GeneralModel"]]
9484
+ Espinita::Audit Load (0.2ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? AND "espinita_audits"."id" = ? LIMIT 1 [["auditable_id", 24], ["auditable_type", "GeneralModel"], ["id", 42]]
9485
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE (auditable_id = 24 and auditable_type = 'GeneralModel' and version <= 1)
9486
+  (0.1ms) begin transaction
9487
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 24 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9488
+ SQL (0.3ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 24], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Ringo\n- MyString\n:settings:\n- Walrus\n- MyText\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 4]]
9489
+ SQL (0.1ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 24 [["name", "MyString"], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9490
+  (0.1ms) commit transaction
9491
+  (0.1ms) begin transaction
9492
+ SQL (0.3ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9493
+  (0.1ms) commit transaction
9494
+  (0.1ms) begin transaction
9495
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 25 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9496
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 25], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Ringo\n:settings:\n- MyText\n- Walrus\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9497
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 25 [["name", "Ringo"], ["settings", "Walrus"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9498
+  (0.1ms) commit transaction
9499
+  (0.1ms) begin transaction
9500
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 25 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9501
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 25], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:position:\n- 1\n- 7\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 2]]
9502
+ SQL (0.1ms) UPDATE "general_models" SET "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 25 [["position", 7], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9503
+  (0.1ms) commit transaction
9504
+  (0.0ms) begin transaction
9505
+  (0.3ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 25 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9506
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 25], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:position:\n- 7\n- 3\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 3]]
9507
+ SQL (0.1ms) UPDATE "general_models" SET "position" = ?, "updated_at" = ? WHERE "general_models"."id" = 25 [["position", 3], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9508
+  (0.1ms) commit transaction
9509
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" ASC LIMIT 1 [["auditable_id", 25], ["auditable_type", "GeneralModel"]]
9510
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? AND "espinita_audits"."id" = ? LIMIT 1 [["auditable_id", 25], ["auditable_type", "GeneralModel"], ["id", 46]]
9511
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE (auditable_id = 25 and auditable_type = 'GeneralModel' and version <= 1)
9512
+  (0.1ms) begin transaction
9513
+  (0.2ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 25 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9514
+ SQL (0.3ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 25], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- Ringo\n- MyString\n:settings:\n- Walrus\n- MyText\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 4]]
9515
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 25 [["name", "MyString"], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9516
+  (0.1ms) commit transaction
9517
+  (0.1ms) begin transaction
9518
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9519
+  (0.1ms) commit transaction
9520
+  (0.3ms) begin transaction
9521
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9522
+  (0.1ms) commit transaction
9523
+  (0.1ms) begin transaction
9524
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 27 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9525
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 27], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n:settings:\n- MyText\n- Bar\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9526
+ SQL (0.2ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 27 [["name", "Foo"], ["settings", "Bar"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9527
+  (0.1ms) commit transaction
9528
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" ASC LIMIT 1 [["auditable_id", 27], ["auditable_type", "GeneralModel"]]
9529
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? AND "espinita_audits"."id" = ? LIMIT 1 [["auditable_id", 26], ["auditable_type", "GeneralModel"], ["id", 50]]
9530
+  (0.1ms) begin transaction
9531
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9532
+  (0.1ms) commit transaction
9533
+  (0.1ms) begin transaction
9534
+ SQL (0.1ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9535
+  (0.1ms) commit transaction
9536
+  (0.0ms) begin transaction
9537
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 29 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9538
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 29], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n:settings:\n- MyText\n- Bar\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9539
+ SQL (0.1ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 29 [["name", "Foo"], ["settings", "Bar"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9540
+  (0.1ms) commit transaction
9541
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? ORDER BY "espinita_audits"."id" ASC LIMIT 1 [["auditable_id", 29], ["auditable_type", "GeneralModel"]]
9542
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? AND "espinita_audits"."id" = ? LIMIT 1 [["auditable_id", 28], ["auditable_type", "GeneralModel"], ["id", 51]]
9543
+  (0.1ms) begin transaction
9544
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9545
+  (0.1ms) commit transaction
9546
+  (0.1ms) begin transaction
9547
+ SQL (0.2ms) INSERT INTO "general_models" ("created_at", "name", "position", "settings", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["name", "MyString"], ["position", 1], ["settings", "MyText"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9548
+  (0.1ms) commit transaction
9549
+  (0.1ms) begin transaction
9550
+  (0.1ms) SELECT MAX("espinita_audits"."version") AS max_id FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = 31 AND "espinita_audits"."auditable_type" = 'GeneralModel'
9551
+ SQL (0.2ms) INSERT INTO "espinita_audits" ("action", "auditable_id", "auditable_type", "audited_changes", "created_at", "remote_address", "updated_at", "user_id", "user_type", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [["action", "update"], ["auditable_id", 31], ["auditable_type", "GeneralModel"], ["audited_changes", "---\n:name:\n- MyString\n- Foo\n:settings:\n- MyText\n- Bar\n"], ["created_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["remote_address", "0.0.0.0"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00], ["user_id", 2], ["user_type", "User"], ["version", 1]]
9552
+ SQL (0.1ms) UPDATE "general_models" SET "name" = ?, "settings" = ?, "updated_at" = ? WHERE "general_models"."id" = 31 [["name", "Foo"], ["settings", "Bar"], ["updated_at", Sun, 24 May 2015 00:59:39 UTC +00:00]]
9553
+  (0.1ms) commit transaction
9554
+ Espinita::Audit Load (0.1ms) SELECT "espinita_audits".* FROM "espinita_audits" WHERE "espinita_audits"."auditable_id" = ? AND "espinita_audits"."auditable_type" = ? AND "espinita_audits"."id" = ? LIMIT 1 [["auditable_id", 30], ["auditable_type", "GeneralModel"], ["id", 999999999]]